From 182b725f43baa96f02c3b6afc9acd7e1b24c65b4 Mon Sep 17 00:00:00 2001 From: SpudGunMan Date: Fri, 4 Oct 2024 17:05:15 -0700 Subject: [PATCH] serviceFiles --- etc/mesh_bot_reporting.timer | 10 ++++++++++ etc/{bot_reporting.tmp => mesh_bot_reporting.tmp} | 8 ++++---- 2 files changed, 14 insertions(+), 4 deletions(-) create mode 100644 etc/mesh_bot_reporting.timer rename etc/{bot_reporting.tmp => mesh_bot_reporting.tmp} (76%) diff --git a/etc/mesh_bot_reporting.timer b/etc/mesh_bot_reporting.timer new file mode 100644 index 0000000..96c35a8 --- /dev/null +++ b/etc/mesh_bot_reporting.timer @@ -0,0 +1,10 @@ +[Unit] +Description=MeshingAround-ReportingTask + +[Timer] +OnUnitActiveSec=1h +OnbootSec=5min +Unit=mesh_bot_reporting.service + +[Install] +WantedBy=timers.target \ No newline at end of file diff --git a/etc/bot_reporting.tmp b/etc/mesh_bot_reporting.tmp similarity index 76% rename from etc/bot_reporting.tmp rename to etc/mesh_bot_reporting.tmp index 1e01f2f..1a26dc6 100644 --- a/etc/bot_reporting.tmp +++ b/etc/mesh_bot_reporting.tmp @@ -3,16 +3,16 @@ # sudo systemctl start mesh_bot.service [Unit] -Description=MESH-BOT-Reporting +Description=MeshingAround-Reporting After=network.target [Service] -Type=simple +Type=oneshot User=pi Group=pi WorkingDirectory=/dir/ -ExecStart=python3 logs/mesh_network_analyzer.py -ExecStop=pkill -f mesh_network_analyzer.py +ExecStart=python3 etc/report_generator5.py +ExecStop=pkill -f report_generator5.py # Disable Python's buffering of STDOUT and STDERR, so that output from the # service shows up immediately in systemd's logs