Skip to content

Commit 4870b2c

Browse files
ShubhamChaturvedi7Shubham Chaturvedi
andauthored
fix(ci): release bot credentials (#1635)
* Allow GHA to git push * fix(CI): Empty commit * fix(ci): release bot credentials --------- Co-authored-by: Shubham Chaturvedi <scchatur@amazon.com>
1 parent a6b127b commit 4870b2c

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

.github/workflows/prod-release.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,28 @@ jobs:
4747
- name: Install dependencies
4848
run: npm ci --unsafe-perm
4949

50+
- name: Configure AWS Credentials for Release
51+
uses: aws-actions/configure-aws-credentials@v5
52+
with:
53+
aws-region: us-west-2
54+
role-to-assume: arn:aws:iam::587316601012:role/GitHub-CI-CI-Bot-Credential-Access-Role-us-west-2
55+
role-session-name: CI_Bot_Release
56+
57+
# Use AWS Secrets Manager GHA to retrieve CI Bot Creds
58+
- name: Get CI Bot Creds Secret
59+
uses: aws-actions/aws-secretsmanager-get-secrets@v2
60+
with:
61+
secret-ids: Github/aws-crypto-tools-ci-bot
62+
parse-json-secrets: true
63+
64+
# Log in as the CI Bot
65+
- name: Log in as CI Bot
66+
run: |
67+
echo ${{ env.GITHUB_AWS_CRYPTO_TOOLS_CI_BOT_ESDK_RELEASE_TOKEN }} > token.txt
68+
gh auth login --with-token < token.txt
69+
rm token.txt
70+
gh auth status
71+
5072
- name: Configure git
5173
env:
5274
BRANCH: ${{ github.event.inputs.branch }}

0 commit comments

Comments
 (0)