Add systemd unit file

This commit is contained in:
Samuel Sloniker 2023-05-06 09:41:10 -07:00
parent 21e0317979
commit 73917c0f88
2 changed files with 21 additions and 0 deletions

17
adsms.service Normal file
View File

@ -0,0 +1,17 @@
# Systemd unit file for the adsms service
# Generated by ChatGPT
[Unit]
Description=Send SMS notifications based on ADS-B data
After=network.target
Requires=tar1090.service
After=tar1090.service
[Service]
User=adsms
Group=adsms
ExecStart=/usr/local/bin/adsms /etc/adsms.json
Restart=always
[Install]
WantedBy=multi-user.target

View File

@ -22,3 +22,7 @@ chmod 640 /etc/adsms.json
cp -f adsms.py /usr/local/bin/adsms
chown root:root /usr/local/bin/adsms
chmod 755 /usr/local/bin/adsms
cp adsms.service /etc/systemd/system/
chown root:root /etc/systemd/system/adsms.service
chmod 644 /etc/systemd/system/adsms.service