Cannot start gunicorn autorun file

I am trying to run the application with gunicorn and nginx , and you had to double it twice to delete and modify the files several times. This time I ran into problems.

First I created the upstart file ...

sudo nano /etc/init/gunicorn.conf

 description "Gunicorn application server handling flowershop" start on runlevel [2345] stop on runlevel [!2345] respawn setuid ubuntu setgid www-data chdir /home/ubuntu/flowershop exec env/bin/gunicorn --workers 3 --bind unix:/home/ubuntu/flowershop/flowershop.sock flowershop.wsgi:application 

Then I ran ...

 sudo service gunicorn start 

And it started!

I had to change the name of the created socket, so I deleted the /etc/init/gunicorn.conf file, created a new upstart file with the same name as the last one, and tried to run sudo service gunicorn start .

Now it returns the following error messages corresponding to the following commands:

 sudo service gunicorn start start: Job failed to start 

& &

 sudo service gunicorn stop stop: Unknown instance: 

This is clearly related to my intervention, but I have no idea how to fix it.

+5
source share
1 answer

A simple way is to reload a bit

 sudo shutdown -r now 
+1
source

Source: https://habr.com/ru/post/1238219/


All Articles