Skip to content

Commit 5138974

Browse files
committed
Use correct token
1 parent 494cce2 commit 5138974

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

.github/workflows/deploy-production.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ jobs:
6060
id: trigger_deployment
6161
run: |
6262
RESPONSE=$(curl -s -o response.json -w "%{http_code}" -X POST "https://api.digitalocean.com/v2/apps/${{ secrets.DIGITALOCEAN_PRODUCTION_APP_ID }}/deployments" \
63-
-H "Authorization: Bearer ${{ secrets.DIGITALOCEAN_ACCESS_TOKEN }}" \
63+
-H "Authorization: Bearer ${{ secrets.DIGITALOCEAN_API_TOKEN }}" \
6464
-H "Content-Type: application/json")
6565
6666
if [ "$RESPONSE" -ne 200 ]; then
@@ -81,13 +81,13 @@ jobs:
8181

8282
- name: Poll Deployment Status
8383
run: |
84-
MAX_RETRIES=20 # Max polling attempts (~10 minutes)
85-
SLEEP_TIME=30 # Time (in seconds) between each poll
84+
MAX_RETRIES=30
85+
SLEEP_TIME=10
8686
COUNTER=0
8787
8888
while [ $COUNTER -lt $MAX_RETRIES ]; do
8989
RESPONSE=$(curl -s -X GET "https://api.digitalocean.com/v2/apps/${{ secrets.DIGITALOCEAN_PRODUCTION_APP_ID }}/deployments/${{ env.deployment_id }}" \
90-
-H "Authorization: Bearer ${{ secrets.DIGITALOCEAN_ACCESS_TOKEN }}" \
90+
-H "Authorization: Bearer ${{ secrets.DIGITALOCEAN_API_TOKEN }}" \
9191
-H "Content-Type: application/json")
9292

9393
STATUS=$(echo "$RESPONSE" | jq -r '.deployment.phase')

0 commit comments

Comments
 (0)