Skip to content

Instantly share code, notes, and snippets.

@makvoid
Created February 21, 2022 05:19
Show Gist options
  • Save makvoid/2e7ff5b36ec924374c88b8efe04e39c0 to your computer and use it in GitHub Desktop.
Save makvoid/2e7ff5b36ec924374c88b8efe04e39c0 to your computer and use it in GitHub Desktop.
AHT20 Systemd files
[Unit]
Description=Climate Monitor using AHT20
After=network-online.target
[Service]
Type=oneshot
WorkingDirectory=/path/to/dir/containing/script
User=pi
ExecStart=python3 aht20.py --location some_location
[Install]
WantedBy=multi-user.target
[Unit]
Description=Automatic timer for climate-monitor
Requires=climate-monitor.service
[Timer]
Unit=climate-monitor.service
OnCalendar=*:0/15
[Install]
WantedBy=timers.target
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment