From b561663aba8c69b30ff14fb985df4cbf28ef0e6a Mon Sep 17 00:00:00 2001 From: Dennis Eriksen Date: Wed, 29 Mar 2023 21:20:40 +0200 Subject: adding user/pass for mqtt, made a service for neohub --- neohub_listener.service | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 neohub_listener.service (limited to 'neohub_listener.service') diff --git a/neohub_listener.service b/neohub_listener.service new file mode 100644 index 0000000..880d08f --- /dev/null +++ b/neohub_listener.service @@ -0,0 +1,17 @@ +[Unit] +Description=Simple service to start neohub listener +StartLimitIntervalSec=100 +StartLimitBurst=5 + +[Service] +Type=simple +EnvironmentFile=%h/energyscripts/.env +WorkingDirectory=%h/energyscripts +ExecStart=%h/energyscripts/venv/bin/python3 -u scripts/neohub.py +Restart=on-failure +TimeoutStopSec=70 +RestartSec=30 +SyslogIdentifier=%N + +[Install] +WantedBy=default.target -- cgit v1.2.3