1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/mobilizon_ynh.git synced 2024-09-03 19:46:19 +02:00
mobilizon_ynh/conf/systemd.service

31 lines
1.1 KiB
Desktop File

[Unit]
Description=__APP__ Mobilizon Service
After=network.target postgresql.service
[Service]
Type=simple
User=__APP__
Group=__APP__
Environment=MIX_ENV=prod
Environment=MOBILIZON_CONFIG_PATH="__INSTALL_DIR__/config.exs"
WorkingDirectory=__INSTALL_DIR__/live/
ExecStart=__INSTALL_DIR__/live/bin/mobilizon start
ExecStop=__INSTALL_DIR__/live/bin/mobilizon stop
KillMode=process
Restart=on-failure
SyslogIdentifier=mobilizon
; Some security directives.
; Ensures that the service process and all its children can never gain new privileges through execve().
NoNewPrivileges=yes
; Use private /tmp and /var/tmp folders inside a new file system namespace, which are discarded after the process stops.
PrivateTmp=yes
; Sets up a new /dev mount for the process and only adds API pseudo devices like /dev/null, /dev/zero or /dev/random but not physical devices. Disabled by default because it may not work on devices like the Raspberry Pi.
PrivateDevices=no
; Mount /usr, /boot, and /etc as read-only for processes invoked by this service.
ProtectSystem=full
[Install]
WantedBy=multi-user.target