Skip to content

Commit 38d6986

Browse files
author
Kamil Sobol
authored
Fix intermittent credential problem on Windows (#2217)
1 parent 59cb4a3 commit 38d6986

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

.github/actions/setup_profile/action.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,15 @@ runs:
1919
with:
2020
role-to-assume: ${{ inputs.role-to-assume }}
2121
aws-region: ${{ inputs.aws-region }}
22-
output-credentials: true # places the credentials in the GH context object rather than setting env vars
23-
# the AWS credentials action does not have an option to configure a profile, so this manually configures one
22+
# Credentials with special characters are not handled correctly on Windows
23+
# when put into profile files. This forces action to retry until credentials without special characters
24+
# are retrieved
25+
# See: https://github.com/aws-actions/configure-aws-credentials/issues/599
26+
# and https://github.com/aws-actions/configure-aws-credentials/issues/528
27+
special-characters-workaround: ${{ contains(runner.os, 'Windows') }}
28+
# places the credentials in the GH context object rather than setting env vars
29+
# the AWS credentials action does not have an option to configure a profile, so this manually configures one
30+
output-credentials: true
2431
- shell: bash
2532
run: |
2633
aws configure set aws_access_key_id ${{ steps.credentials.outputs.aws-access-key-id }} --profile ${{ inputs.profile-name }}

0 commit comments

Comments
 (0)