Skip to content

Commit 171fe60

Browse files
update github action
1 parent 40523fd commit 171fe60

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

.github/workflows/oidc.example.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,24 @@ name: oidc.example
33

44
on:
55
workflow_dispatch:
6+
7+
jobs:
8+
caller-identity:
9+
name: check caller identity
10+
# These permissions are needed to interact with GitHub's OIDC Token endpoint.
11+
permissions:
12+
contents: read
13+
id-token: write
14+
runs-on: ubuntu-latest
15+
16+
steps:
17+
18+
- name: Configure AWS credentials
19+
uses: aws-actions/configure-aws-credentials@v1
20+
with:
21+
aws-region: ${{ secrets.AWS_REGION }}
22+
role-to-assume: ${{ secrets.AWS_ROLE_TO_ASSUME }} # github_oidc_role
23+
24+
- run: aws sts get-caller-identity
25+
26+
- run: aws s3 ls

0 commit comments

Comments
 (0)