diff options
Diffstat (limited to 'energyscripts-SCRIPT@ADDRESS.service')
-rw-r--r-- | energyscripts-SCRIPT@ADDRESS.service | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/energyscripts-SCRIPT@ADDRESS.service b/energyscripts-SCRIPT@ADDRESS.service new file mode 100644 index 0000000..ab26429 --- /dev/null +++ b/energyscripts-SCRIPT@ADDRESS.service @@ -0,0 +1,26 @@ +[Unit] +Description = Simple service to start mqtt-listener +StartLimitIntervalSec = 100 +StartLimitBurst = 5 + +[Service] +User = energy +Group = energy + +Type = simple +EnvironmentFile = /opt/energyscripts/.env +WorkingDirectory = /opt/energyscripts +ExecStart = /opt/energyscripts/venv/bin/python3 -u scripts/%j.py -a %i +Restart = on-failure +TimeoutStopSec = 70 +RestartSec = 30 +SyslogIdentifier = %N + +NoNewPrivileges = true +ProtectHome = tmpfs +ProtectSystem = full +PrivateDevices = true +ReadWritePaths = /opt/energyscripts/queue + +[Install] +WantedBy = default.target |