summary refs log tree commit diff
path: root/modules/auto-redeploy.nix
diff options
context:
space:
mode:
Diffstat (limited to 'modules/auto-redeploy.nix')
-rw-r--r--modules/auto-redeploy.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/auto-redeploy.nix b/modules/auto-redeploy.nix
index 4b2a640..e3b81fc 100644
--- a/modules/auto-redeploy.nix
+++ b/modules/auto-redeploy.nix
@@ -18,7 +18,6 @@
         #after = [ "network.target" ];
         serviceConfig = {
             ExecStart = pkgs.writeShellScript "auto-redeploy" ''
-              ${pkgs.curl}/bin/curl -S -H "Content-Type: application/json" -d '{"username": "${config.networking.hostName} - redeploy", "content": "System started redeploy."}' ${secrets.webhooks.discord.deploy}
               cd /Spacebar-Open-Architecture
               #store current commit hash
               echo "Current commit: $(${pkgs.git}/bin/git rev-parse HEAD)"
@@ -32,6 +31,7 @@
                 echo "Already up-to-date"
                 exit 0
               fi
+              ${pkgs.curl}/bin/curl -S -H "Content-Type: application/json" -d '{"username": "${config.networking.hostName} - redeploy", "content": "System started redeploy."}' ${secrets.webhooks.discord.deploy}
               #pull new commits
               ${pkgs.git}/bin/git pull
               #send commit log to discord