[Unit] Description=Evection (gunicorn) After=network.target redis-server.service [Service] Type=simple User=evection Group=evection WorkingDirectory=/opt/evection/app EnvironmentFile=/opt/evection/app/.env Environment=DJANGO_SETTINGS_MODULE=config.settings.prod # Evection is always meant to sit behind a reverse proxy (see # docs/install.md) — it listens on a plain TCP address, never a Unix # socket, so that proxy can be on this host or a different one. # EVECTION_GUNICORN_BIND (set in .env by scripts/install.sh) controls # what address:port that is. ExecStart=/bin/sh -c 'exec /opt/evection/venv/bin/gunicorn --workers 3 --bind "$EVECTION_GUNICORN_BIND" config.wsgi:application' ExecReload=/bin/kill -s HUP $MAINPID Restart=on-failure NoNewPrivileges=true PrivateTmp=true ProtectSystem=strict ReadWritePaths=/opt/evection/app [Install] WantedBy=multi-user.target