Skip to content

Instantly share code, notes, and snippets.

@discountry
Created April 23, 2023 08:27
Show Gist options
  • Select an option

  • Save discountry/fd12e0d42951e9a63e46361a871ef2e4 to your computer and use it in GitHub Desktop.

Select an option

Save discountry/fd12e0d42951e9a63e46361a871ef2e4 to your computer and use it in GitHub Desktop.
[Unit]
Description=gunicorn daemon
Requires=gunicorn.socket
After=network.target
[Service]
Type=notify
# the specific user that our service will run as
User=dev
Group=dev
# another option for an even more restricted service is
# DynamicUser=yes
# see http://0pointer.net/blog/dynamic-users-with-systemd.html
RuntimeDirectory=gunicorn
WorkingDirectory=/home/xxx/gpt4free/client
ExecStart=/home/xxx/.local/bin/gunicorn 'app:app'
ExecReload=/bin/kill -s HUP $MAINPID
KillMode=mixed
TimeoutStopSec=5
PrivateTmp=true
[Install]
WantedBy=multi-user.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment