From 012ed87156abaeaede50ed9e0e37fdf21a3837ea Mon Sep 17 00:00:00 2001 From: alex 3 Date: Sun, 5 Nov 2023 18:22:14 -0500 Subject: [PATCH] Add rebuild action --- .github/workflows/rebuild.yml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 .github/workflows/rebuild.yml diff --git a/.github/workflows/rebuild.yml b/.github/workflows/rebuild.yml new file mode 100644 index 0000000..34c816f --- /dev/null +++ b/.github/workflows/rebuild.yml @@ -0,0 +1,22 @@ +name: Trigger pull & rebuild + +on: + push: + branches: + - main + +jobs: + post: + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v2 + + - name: Send POST request + run: | + curl -X POST \ + -H "Content-Type: application/json" \ + -H "Authorization: Bearer ${{ secrets.PTERO_TOKEN }}" \ + -d '{"signal": "restart"}' \ + https://panel.thatalex.dev/api/client/servers/457f4d77/power