I am running a django site using uWSGI in emperor mode. I have found that while touching the uwsgi.ini file for a specific application does indeed cause the emperor process to reload that vassal (according to the log file) that a reload is not enough to pick up changes. Specifically changes to the .env file used to configure the django site.

If I move the app specific uwsgi.ini file out of the vassals folder and back in it will work. Presumably because the emperor process kills the vassals once the .ini file is missing and the restarts them when the file reappears. Also restarting the uwsgi emperor using systemd works as well.

I rather not restart the emperor process and the process of moving the ini file around feels awful clunky.

What is the right way to restart single Django site behind emperor and still pick up changes to the site settings?


emperor = /etc/uwsgi/vassals
uid = www-data
gid = www-data
limit-as = 1024
logto = /tmp/uwsgi.log



master = true
processes = 2

socket =
chmod-socket = 664
vacuum = true

1 Answer 1


To restart the single vassal just touch the file

# touch /etc/uwsgi/vassals/demo-app.ini

Uwsgi will detect the change and restart that single service.

  • 1
    Note that this appears to not do a full restart - all workers are killed and restarted and the master process re-execs itself, but the emperor does not not restart the master process. This means that some options (I suspect the ones that need root, I've seen this with listen and cgroup) are not re-applied in this case. On trick to work around this seems to move the .ini file outside of the vassals directory, killing the vassal, and then moving it back to restart it from scratch. Jun 9, 2020 at 9:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.