I have a script that launches my website located in /home/webserver/run-website
#!/bin/bash
echo "launching website..."
service nginx start
cd /home/webserver/django_personal_website
screen -S website /home/webserver/uwsgi_run
and the uwsgi_run file looks like this
#!/bin/bash
uwsgi --socket blog.sock --module django_personal_website.wsgi --chmod-socket=666
when I try independently testing the first script with ./run-website, it works just fine.
I want Crontab to execute this script on reboot so I added the following line to sudo crontab -e
@reboot bash /home/webserver/run-website
I even tested just the command bash /home/webserver/run-website in the terminal and it works too but for some reason when I reboot my PC it doesn't launch the website.
Does anyone have any idea why that might be happening?