From bd9512d369976db694241f6b97454fafd6850227 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=94=D0=BC=D0=B8=D1=82=D1=80=D0=B8=D0=B9=20=D0=90=D0=B1?= =?UTF-8?q?=D0=B4=D1=80=D0=B0=D1=85=D0=BC=D0=B0=D0=BD=D0=BE=D0=B2?= <565963@gmail.com> Date: Fri, 18 Oct 2024 17:58:47 +0300 Subject: [PATCH] chore --- services/wthrc.service | 1 + src/installer.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/services/wthrc.service b/services/wthrc.service index 826b857..abb5c0e 100644 --- a/services/wthrc.service +++ b/services/wthrc.service @@ -1,6 +1,7 @@ [Unit] Description=Weather collection service + [Service] Type=simple WorkingDirectory=/home/citrullux/ModernOSLabs/src diff --git a/src/installer.py b/src/installer.py index 1b23898..c40cf09 100644 --- a/src/installer.py +++ b/src/installer.py @@ -19,8 +19,8 @@ def install() -> None: # Fix for weather service with open(os.path.join(projectDir, "services/wthrc.service"), "r") as service: lines = service.readlines() - lines[5] = "WorkingDirectory=" + os.path.join(projectDir, "src") + "\n" - lines[6] = ( + lines[6] = "WorkingDirectory=" + os.path.join(projectDir, "src") + "\n" + lines[7] = ( "ExecStart=" + pythonPath + " " + os.path.join(projectDir, "src/main.py") + "\n" ) with open(os.path.join(projectDir, "services/wthrc.service"), "w") as service: