Configuring UWSGI with Python, Django, and NGINX: Difference between revisions
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
Create a service in '''/etc/systemd/system/uwsgi.service''' | Create a service in '''/etc/systemd/system/uwsgi.service''' | ||
< | <pre> | ||
[Unit] | [Unit] | ||
Description=uWSGI Emperor service | Description=uWSGI Emperor service | ||
Line 16: | Line 16: | ||
[Install] | [Install] | ||
WantedBy=multi-user.target</ | WantedBy=multi-user.target</pre> |
Revision as of 12:37, 1 November 2020
Create a service in /etc/systemd/system/uwsgi.service
[Unit] Description=uWSGI Emperor service [Service] ExecStartPre=/bin/bash -c 'mkdir -p /run/uwsgi; chown www-data:www-data /run/uwsgi' #ExecStart=/usr/local/bin/uwsgi --emperor /etc/uwsgi/sites #ExecStart=/usr/local/bin/uwsgi --http 0.0.0.0:8001 --wsgi-file stocks/wsgi.py --master -b 30000 --enable-threads --processes 4 --threads 2 ExecStart=/usr/local/bin/uwsgi --emperor /etc/uwsgi/sites Restart=always KillSignal=SIGQUIT Type=notify NotifyAccess=all [Install] WantedBy=multi-user.target