[Unit] Description=Serial heartbeat responder After=network.target [Service] Type=notify NotifyAccess=all Environment=PYTHONUNBUFFERED=1 Environment=SERIAL_PORT=/dev/ttyUSB0 Environment=SERIAL_BAUDRATE=9600 ExecStart=/usr/bin/env python3 /opt/watch-watch-server/serial_heartbeat.py --port ${SERIAL_PORT} --baudrate ${SERIAL_BAUDRATE} Restart=on-failure RestartSec=3 WatchdogSec=20 WorkingDirectory=/opt/watch-watch-server StandardOutput=journal StandardError=inherit [Install] WantedBy=multi-user.target