77
88---
99
10- ### News
10+ ### Recent News
11+
12+ #### v4 Announcement (9/11/23)
13+
14+ We have just released ` v4 ` of Configure AWS Credentials. The only thing that
15+ changed from ` v3 ` is that the action now runs on ` node20 ` instead of ` node16 ` .
16+ You can still see the ` v3 ` announcement below, as it is still recent.
17+
18+ #### v3 Announcement (8/23/23)
1119
1220We have recently released ` v3 ` of Configure AWS Credentials! With this new
1321release we have migrated the code to TypeScript, and have also migrated away
@@ -82,7 +90,7 @@ To do that, you would add the following step to your workflow:
8290
8391``` yaml
8492 - name : Configure AWS Credentials
85- uses : aws-actions/configure-aws-credentials@v3
93+ uses : aws-actions/configure-aws-credentials@v4
8694 with :
8795 role-to-assume : arn:aws:iam::123456789100:role/my-github-actions-role
8896 aws-region : us-east-2
@@ -111,15 +119,15 @@ jobs:
111119 - name: Checkout
112120 uses: actions/checkout@v3
113121 - name: Configure AWS credentials from Test account
114- uses: aws-actions/configure-aws-credentials@v3
122+ uses: aws-actions/configure-aws-credentials@v4
115123 with:
116124 role-to-assume: arn:aws:iam::111111111111:role/my-github-actions-role-test
117125 aws-region: us-east-1
118126 - name: Copy files to the test website with the AWS CLI
119127 run: |
120128 aws s3 sync . s3://my-s3-test-website-bucket
121129 - name: Configure AWS credentials from Production account
122- uses: aws-actions/configure-aws-credentials@v3
130+ uses: aws-actions/configure-aws-credentials@v4
123131 with:
124132 role-to-assume: arn:aws:iam::222222222222:role/my-github-actions-role-prod
125133 aws-region: us-west-2
@@ -209,7 +217,7 @@ within the Action. See [issue 419](https://github.com/aws-actions/configure-aws-
209217You can skip this session tagging by providing
210218`role-skip-session-tagging` as true in the action's inputs :
211219` ` ` yaml
212- uses: aws-actions/configure-aws-credentials@v3
220+ uses: aws-actions/configure-aws-credentials@v4
213221 with:
214222 role-skip-session-tagging: true
215223` ` `
@@ -220,13 +228,13 @@ You can skip this session tagging by providing
220228An IAM policy in stringified JSON format that you want to use as an inline session policy.
221229Depending on preferences, the JSON could be written on a single line like this :
222230` ` ` yaml
223- uses: aws-actions/configure-aws-credentials@v3
231+ uses: aws-actions/configure-aws-credentials@v4
224232 with:
225233 inline-session-policy: '{"Version":"2012-10-17","Statement":[{"Sid":"Stmt1","Effect":"Allow","Action":"s3:List*","Resource":"*"}]}'
226234` ` `
227235Or we can have a nicely formatted JSON as well :
228236` ` ` yaml
229- uses: aws-actions/configure-aws-credentials@v3
237+ uses: aws-actions/configure-aws-credentials@v4
230238 with:
231239 inline-session-policy: >-
232240 {
@@ -246,13 +254,13 @@ Or we can have a nicely formatted JSON as well:
246254The Amazon Resource Names (ARNs) of the IAM managed policies that you want to use as managed session policies.
247255The policies must exist in the same account as the role. You can pass a single managed policy like this :
248256` ` ` yaml
249- uses: aws-actions/configure-aws-credentials@v3
257+ uses: aws-actions/configure-aws-credentials@v4
250258 with:
251259 managed-session-policies: arn:aws:iam::aws:policy/AmazonS3ReadOnlyAccess
252260` ` `
253261And we can pass multiple managed policies likes this :
254262` ` ` yaml
255- uses: aws-actions/configure-aws-credentials@v3
263+ uses: aws-actions/configure-aws-credentials@v4
256264 with:
257265 managed-session-policies: |
258266 arn:aws:iam::aws:policy/AmazonS3ReadOnlyAccess
@@ -295,7 +303,7 @@ When the JWT is created, an audience needs to be specified. By default, the audi
295303
296304` ` ` yaml
297305 - name: Configure AWS Credentials for China region audience
298- uses: aws-actions/configure-aws-credentials@v3
306+ uses: aws-actions/configure-aws-credentials@v4
299307 with:
300308 audience: sts.amazonaws.com.cn
301309 aws-region: us-east-3
@@ -407,7 +415,7 @@ You can use this action to simply configure the region and account ID in the
407415environment, and then use the runner's credentials for all AWS API calls made by
408416your Actions workflow :
409417` ` ` yaml
410- uses: aws-actions/configure-aws-credentials@v3
418+ uses: aws-actions/configure-aws-credentials@v4
411419with:
412420 aws-region: us-east-2
413421` ` `
@@ -417,7 +425,7 @@ APIs called by your Actions workflow.
417425Or, you can use this action to assume a role, and then use the role credentials
418426for all AWS API calls made by your Actions workflow :
419427` ` ` yaml
420- uses: aws-actions/configure-aws-credentials@v3
428+ uses: aws-actions/configure-aws-credentials@v4
421429with:
422430 aws-region: us-east-2
423431 role-to-assume: my-github-actions-role
@@ -440,7 +448,7 @@ environment.
440448
441449Manually configured proxy :
442450` ` ` yaml
443- uses: aws-actions/configure-aws-credentials@v3
451+ uses: aws-actions/configure-aws-credentials@v4
444452with:
445453 aws-region: us-east-2
446454 role-to-assume: my-github-actions-role
@@ -470,7 +478,7 @@ should include the AWS CLI by default.
470478# ## AssumeRoleWithWebIdentity (recommended)
471479` ` ` yaml
472480 - name: Configure AWS Credentials
473- uses: aws-actions/configure-aws-credentials@v3
481+ uses: aws-actions/configure-aws-credentials@v4
474482 with:
475483 aws-region: us-east-2
476484 role-to-assume: arn:aws:iam::123456789100:role/my-github-actions-role
@@ -481,13 +489,13 @@ In this example, the Action will load the OIDC token from the GitHub-provided en
481489# ## AssumeRole with role previously assumed by action in same workflow
482490` ` ` yaml
483491 - name: Configure AWS Credentials
484- uses: aws-actions/configure-aws-credentials@v3
492+ uses: aws-actions/configure-aws-credentials@v4
485493 with:
486494 aws-region: us-east-2
487495 role-to-assume: arn:aws:iam::123456789100:role/my-github-actions-role
488496 role-session-name: MySessionName
489497 - name: Configure other AWS Credentials
490- uses: aws-actions/configure-aws-credentials@v3
498+ uses: aws-actions/configure-aws-credentials@v4
491499 with:
492500 aws-region: us-east-2
493501 role-to-assume: arn:aws:iam::987654321000:role/my-second-role
@@ -499,7 +507,7 @@ In this two-step example, the first step will use OIDC to assume the role `arn:a
499507# ## AssumeRole with static IAM credentials in repository secrets
500508` ` ` yaml
501509 - name: Configure AWS Credentials
502- uses: aws-actions/configure-aws-credentials@v3
510+ uses: aws-actions/configure-aws-credentials@v4
503511 with:
504512 aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
505513 aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
@@ -515,7 +523,7 @@ In this example, the secret `AWS_ROLE_TO_ASSUME` contains a string like `arn:aws
515523` ` ` yaml
516524 - name: Configure AWS Credentials 1
517525 id: creds
518- uses: aws-actions/configure-aws-credentials@v3
526+ uses: aws-actions/configure-aws-credentials@v4
519527 with:
520528 aws-region: us-east-2
521529 role-to-assume: arn:aws:iam::123456789100:role/my-github-actions-role
@@ -524,7 +532,7 @@ In this example, the secret `AWS_ROLE_TO_ASSUME` contains a string like `arn:aws
524532 run: |
525533 aws sts get-caller-identity
526534 - name: Configure AWS Credentials 2
527- uses: aws-actions/configure-aws-credentials@v3
535+ uses: aws-actions/configure-aws-credentials@v4
528536 with:
529537 aws-region: us-east-2
530538 aws-access-key-id: ${{ steps.creds.outputs.aws-access-key-id }}
0 commit comments