[Unit] Description=weather-logger-receiver After=network.target StartLimitIntervalSec=0 [Service] Type=simple Restart=always RestartSec=1 User=weather-logger Group=weather-logger Environment=PYTHONUNBUFFERED=1 StandardOutput=syslog StandardError=syslog SyslogIdentifier=weather-logger-receiver PIDFile=/run/weather_logger/receiver.pid PermissionsStartOnly=true ExecStartPre=mkdir -p /run/weather_logger /var/log/weather_logger /usr/local/share/weather_logger ExecStartPre=rm -f /run/weather_logger/receiver.pid ExecStartPre=chown -R weather-logger:weather-logger /run/weather_logger /var/log/weather_logger /usr/local/share/weather_logger ExecStopPost=rm -f /run/weather_logger/receiver.pid ExecStart=/usr/local/src/weather_logger/weather-logger-receiver /etc/weather-logger-receiver.yaml [Install] WantedBy=multi-user.target