Skip to content

Commit

Permalink
delete runner if still existing
Browse files Browse the repository at this point in the history
  • Loading branch information
fkz committed Sep 22, 2023
1 parent 48dffe6 commit 84cb3fd
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,15 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: 3bit/setup-hcloud@v2
- run: |
- name: Delete runner if existing
run: |
hcloud server delete runner
if !$?; then echo "Deleting runner failed"; fi
env:
HCLOUD_TOKEN: ${{ secrets.HCLOUD_TOKEN }}

- name: Deploy new runner
run: |
curl https://raw.githubusercontent.com/potsdam-pnp/runner/main/.github/workflows/user-data.txt > user-data.txt
hcloud server create \
--image ubuntu-22.04 \
Expand Down

0 comments on commit 84cb3fd

Please sign in to comment.