diff --git a/conf/systemd.service b/conf/systemd.service index 36088ee..c193495 100644 --- a/conf/systemd.service +++ b/conf/systemd.service @@ -1,19 +1,23 @@ [Unit] -Description=Movim: web-based XMPP client -After=nginx.service network.target local-fs.target postgresql.service +Description=Movim: responsive web-based XMPP client +After=nginx.service network.target local-fs.target [Service] Type=simple User=__APP__ Group=__APP__ +Environment=PUBLIC_URL=https://__DOMAIN____PATH__/ +Environment=WS_PORT=__PORT__ +EnvironmentFile__INSTALL_DIR__/ WorkingDirectory=__INSTALL_DIR__/ ExecStart=/usr/bin/php__PHPVERSION__ daemon.php start StandardOutput=syslog SyslogIdentifier=__APP__ PIDFile=/run/movim.pid -#Restart=on-failure +Restart=on-failure RestartSec=10 + # Sandboxing options to harden security # Depending on specificities of your service/app, you may need to tweak these # .. but this should be a good baseline