From d6c6436c0f9d825a7195c28606e6138d13d12732 Mon Sep 17 00:00:00 2001 From: Casper da Costa-Luis Date: Fri, 28 Jul 2023 14:37:14 +0100 Subject: [PATCH] ci: machine start fix --- .github/workflows/ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 063c447..a8bd085 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,7 +26,7 @@ jobs: while test $(curl -fsSL -X GET -H "X-Api-Key: $API_KEY" https://api.paperspace.io/machines/getMachinePublic?machineId=$MACHINE | jq -r .state) != ready; do sleep 5 done - IP=$(curl -fsSL -X GET -H "X-Api-Key: $API_KEY" $API_INFO?machineId=$MACHINE_ID | jq -r .publicIpAddress) + IP=$(curl -fsSL -X GET -H "X-Api-Key: $API_KEY" https://api.paperspace.io/machines/getMachinePublic?machineId=$MACHINE_ID | jq -r .publicIpAddress) echo "$SSH_KEY" > key ssh -o "StrictHostKeyChecking no" -i key paperspace@$IP 'touch "gha-run-${{ github.run_id }}.lock"' env: @@ -80,7 +80,7 @@ jobs: - uses: actions/checkout@v3 - name: Stop self-hosted runners run: | - IP=$(curl -fsSL -X GET -H "X-Api-Key: $API_KEY" $API_INFO?machineId=$MACHINE_ID | jq -r .publicIpAddress) + IP=$(curl -fsSL -X GET -H "X-Api-Key: $API_KEY" https://api.paperspace.io/machines/getMachinePublic?machineId=$MACHINE_ID | jq -r .publicIpAddress) echo "$SSH_KEY" > key ssh -o "StrictHostKeyChecking no" -i key paperspace@$IP \ 'rm -f "gha-run-${{ github.run_id }}.lock"; sleep 10; ls gha-run-*.lock' || \