summary refs log tree commit diff
diff options
context:
space:
mode:
authorTheArcaneBrony <myrainbowdash949@gmail.com>2023-04-04 04:50:48 +0200
committerRory& <root@rory.gay>2024-06-05 17:25:16 +0200
commitad86401bf225424539d1b50d7b1a1e3f715e4e93 (patch)
tree1d189a976a1e4ce57ecbb131092e413cf7111e85
parentCleaner redeploy message (diff)
downloadSpacebar-Open-Infrastructure-ad86401bf225424539d1b50d7b1a1e3f715e4e93.tar.xz
Attempt to fix auto-redeploy
-rw-r--r--modules/auto-redeploy.nix8
1 files changed, 6 insertions, 2 deletions
diff --git a/modules/auto-redeploy.nix b/modules/auto-redeploy.nix
index ae415ca..d082ebb 100644
--- a/modules/auto-redeploy.nix
+++ b/modules/auto-redeploy.nix
@@ -49,8 +49,12 @@
                 nixos-rebuild switch --flake ".#${config.networking.hostName}" -j`nproc` --upgrade-all
                 git rm --cached hardware-configuration.nix
               ) 2>&1 | tee /tmp/update.log
-              #send the output to discord as a file
-              curl -S -F "file=@/tmp/update.log" -F "filename=update.log" -F "content=System finished redeploy. Logs:" -H "Content-Type: multipart/form-data" ${secrets.webhooks.discord.deploy}
+              #send the output to discord as a file, with hostname as username, use paload_json
+              curl -S -F "file=@/tmp/update.log" -F "filename=update.log" -F 'payload_json={"username": "${config.networking.hostName} - redeploy", "content": "Redeploy finished! Logs:"}' -H "Content-Type: multipart/form-data" ${secrets.webhooks.discord.deploy}
+              
+
+
+              
               #store current commit in file
               echo $(git rev-parse HEAD) > currentCommit
               '';