A reference implementation of Configuring OpenID Connect in Amazon Web Services
oidc-cloudformation.yml:
A cloudformation stack to be manually deployed to create an IAM Role that GitHub Actions can assume to deploy an application via CloudFormation
app-cloudformation.yml:
The example application stack to be deployed via GitHub Actions
.github/workflows/deploy.yaml:
The GitHub Actions workflow that assumes the OIDC IAM Role to deploy the application stack
- Manually deploy oidc-cloudformation.yml
- Create the
AWS_DEFAULT_REGION,STACK_NAME, andOIDC_ROLE_ARNvariables in Repository Settings -> Secrets and variables -> ActionsOIDC_ROLE_ARNis the ARN of the IAM role created in step 1, available as an output of the OIDC stack
- Run the
deployaction via Workflow Dispatch to deploy the application stack