gunicorn service 등록
gunicorn service
Gunicorn 설치
pip3 install gunicorn
Gunicorn service 설정
vi /etc/systemd/system/gunicorn.service
[Unit]
Description=gunicorn daemon
After=network.target
[Service]
User=foo
Group=www-data
WorkingDirectory=/home/foo/django_test/repo
ExecStart=/root/venv_manager/bin/gunicorn \
--workers 3 \
--bind unix:/home/foo/django_test/run/gunicorn.sock \
conf.wsgi:application
[Install]
WantedBy=multi-user.target
systemctl daemon-reload
systemctl start gunicorn