From eb24a3ee5d99a6240c6ec0269bea9782720d11e1 Mon Sep 17 00:00:00 2001 From: Dirk Alders Date: Wed, 24 Aug 2022 13:17:06 +0100 Subject: [PATCH] Systemctl service update --- __install__.py | 3 ++- config_example/config.py | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/__install__.py b/__install__.py index 200a4f4..a05e3ef 100644 --- a/__install__.py +++ b/__install__.py @@ -6,7 +6,8 @@ import sys SERVICE_FILE = """ [Unit] Description=Powerplug Service -After=mosquitto.target +After=network-online.target +Wants=network-online.target [Service] User=%(UID)d Group=%(GID)d diff --git a/config_example/config.py b/config_example/config.py index aa3fc4a..b838d7a 100644 --- a/config_example/config.py +++ b/config_example/config.py @@ -6,17 +6,17 @@ import report MQTT_USER = "user" MQTT_PASS = "pass" MQTT_SERVER = "localhost" -MQTT_TOPIC = "hifi/powerplug" +MQTT_TOPIC = "dirk/powerplug" # # Logging # __BASEPATH__ = os.path.abspath(os.path.dirname(__file__)) APP_NAME = "powerplug" -LOGTARGET = 'logfile' # possible choices are: 'logfile' or 'stdout' +LOGTARGET = 'stdout' # possible choices are: 'logfile' or 'stdout' LOGLVL = 'DEBUG' LOGHOST = 'cutelog' LOGPORT = 19996 -formatter = report.LONG_FMT +formatter = report.SHORT_FMT