Skip to content

Commit e173704

Browse files
authored
Merge pull request #457 from NHSDigital/CCM-981-proxy-deployment-retries
CCM-981
2 parents 334a6a6 + 8cfd805 commit e173704

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

azure/components/get-access-token.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,15 @@ steps:
2222
2323
- bash: |
2424
set -euo pipefail
25+
26+
# fetch the access token
2527
curl -X POST https://${{ parameters._auth_server[parameters.apigee_organization] }}/oauth/token \
2628
-H "Content-Type: application/x-www-form-urlencoded" \
2729
-H "Accept: application/json;charset=utf-8" \
2830
-H "Authorization: Basic ZWRnZWNsaTplZGdlY2xpc2VjcmV0" \
29-
-d "username=${{ parameters.apigee_username }}&password=${{ parameters.apigee_password }}&mfa_token=$(secret.MFACode)&grant_type=password" | jq .access_token > .token
31+
-d "username=${{ parameters.apigee_username }}&password=${{ parameters.apigee_password }}&mfa_token=$(secret.MFACode)&grant_type=password" | jq -e .access_token > .token
3032
3133
# Set token into variable
3234
echo "##vso[task.setvariable variable=secret.AccessToken;issecret=true]`cat .token`"
3335
displayName: 'Get Apigee Access Token'
36+
retryCountOnTaskFailure: 5

0 commit comments

Comments
 (0)