1

Does my deploy user need to belong to the sudoer list for Upstart to start GUnicorn?

Here is the error from my Upstart log

deploy is not in the sudoers file. This incident will be reported.

It works fine if I do not specify the setuid and setgid. But I suspect that running the process as root is not a good idea. This is the upstart script that I'm running:

description "Gunicorn for django_instance"

start on (filesystem) stop on runlevel [016]

respawn console log

# Setting these to nobody and nogroup does not work either # setuid nobody # setgid nogroup

setuid deploy

setgid deploy

script

chdir /home/deploy/django_instance
exec sudo -u deploy -g deploy /home/deploy/venvs/test_env/bin/gunicorn django_instance.wsgi:application

end script

indi
  • 181
  • 5
  • The upstart version I'm using is the one which comes default with Ubuntu 12.04.2 LTS – indi Aug 02 '13 at 10:38

0 Answers0