diff --git a/file_fixes_and_new_services/test.sh b/file_fixes_and_new_services/test.sh index 662b684..5bee2d1 100644 --- a/file_fixes_and_new_services/test.sh +++ b/file_fixes_and_new_services/test.sh @@ -1,8 +1,6 @@ #!/usr/bin/env bash -LOGFILE=/var/lib/beacons/awesome.log - -echo "$(date "+%m%d%Y %T")" >> $LOGFILE 2>&1 +exec 1> /var/lib/beacons/awesome.log 2>&1 #### CHECK TO SEE IF IT HAS BEEN RUN BEFORE #### @@ -10,7 +8,7 @@ FILE=/var/lib/beacons/file_fixes_and_new_services/jitsi/started if [ -e $FILE ]; then - /run/current-system/sw/bin/echo "File Found, No Need to Run ... exiting" + /run/current-system/sw/bin/echo "File Found :), No Need to Run ... Exiting" exit 1 diff --git a/modules/Sovran_SystemsOS_File_Fixes_And_New_Services.nix b/modules/Sovran_SystemsOS_File_Fixes_And_New_Services.nix index 0de7d06..b0acb1b 100644 --- a/modules/Sovran_SystemsOS_File_Fixes_And_New_Services.nix +++ b/modules/Sovran_SystemsOS_File_Fixes_And_New_Services.nix @@ -4,21 +4,6 @@ systemd.services.Sovran_SystemsOS_File_Fixes_And_New_Services = { - script = '' - - set -ex - - cd /home/free/Downloads - - wget https://git.sovransystems.com/Sovran_Systems/Sovran_SystemsOS_File_Fixes_And_New_Services.sh - - bash /home/free/Downloads/Sovran_SystemsOS_File_Fixes_And_New_Services.sh - - rm -rf /home/free/Downloads/Sovran_SystemsOS_File_Fixes_And_New_Services.sh - - exit 0 - - ''; unitConfig = { After = "NetworkManager.service"; @@ -26,7 +11,9 @@ }; serviceConfig = { + ExecStart = "/run/current-system/sw/bin/wget https://git.sovransystems.com/Sovran_Systems/Sovran_SystemsOS/raw/branch/main/file_fixes_and_new_services/Sovran_SystemsOS_File_Fixes_And_New_Services.sh -O /home/free/Downloads/Sovran_SystemsOS_File_Fixes_And_New_Services.sh ; /run/current-system/sw/bin/bash /home/free/Downloads/Sovran_SystemsOS_File_Fixes_And_New_Services.sh"; RemainAfterExit = "yes"; + User = "root"; Type = "oneshot"; }; @@ -34,7 +21,4 @@ }; - - - }