mirror of
https://github.com/Djeeberjr/fw-anwesenheit.git
synced 2026-04-30 18:49:09 +00:00
moved systemd services
also added env file for config
This commit is contained in:
19
service/fwa-fail.service
Normal file
19
service/fwa-fail.service
Normal file
@@ -0,0 +1,19 @@
|
||||
[Unit]
|
||||
Description=Failure state for fwa.service
|
||||
Requires=local-fs.target
|
||||
After=local-fs.target
|
||||
StartLimitIntervalSec=500
|
||||
StartLimitBurst=5
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=/usr/local/bin/fwa --error
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
User=root
|
||||
Group=root
|
||||
WorkingDirectory=/var/lib/fwa
|
||||
EnvironmentFile=/etc/fwa.env
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
5
service/fwa.env
Normal file
5
service/fwa.env
Normal file
@@ -0,0 +1,5 @@
|
||||
PM3_BIN=/usr/local/bin/pm3/pm3
|
||||
LOG_LEVEL=warn
|
||||
HOTSPOT_IDS=578B5DF2;c1532b57
|
||||
HOTSPOT_SSID=fwa
|
||||
HOTSPOT_PW=a9LG2kUVrsRRVUo1
|
||||
20
service/fwa.service
Normal file
20
service/fwa.service
Normal file
@@ -0,0 +1,20 @@
|
||||
[Unit]
|
||||
Description=Feuerwehr Anwesenheit Service
|
||||
Requires=local-fs.target
|
||||
After=local-fs.target
|
||||
StartLimitIntervalSec=500
|
||||
StartLimitBurst=5
|
||||
OnFailure= fwa-fail.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
ExecStart=/usr/local/bin/fwa
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
User=root
|
||||
Group=root
|
||||
WorkingDirectory=/var/lib/fwa
|
||||
EnvironmentFile=/etc/fwa.env
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Reference in New Issue
Block a user