Skip to content

Commit 6d18658

Browse files
committed
use assume role
Signed-off-by: Tao Liu <liutaoaz@amazon.com>
1 parent 3dfb0c6 commit 6d18658

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

.github/workflows/deployment-template.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ on:
4444
required: false
4545
root_ca_cert:
4646
required: false
47+
aws_account_id:
48+
required: false
4749
jobs:
4850

4951
OS-OSD-Deployment:
@@ -131,7 +133,7 @@ jobs:
131133
- name: Step 6 - Configure AWS Credentials
132134
uses: aws-actions/configure-aws-credentials@v4
133135
with:
134-
role-to-assume: arn:aws:iam::${{ secrets.AWS_ACCOUNT_ID_PREVIEW }}:role/ekspreviewadminrole-github
136+
role-to-assume: arn:aws:iam::${{ secrets.aws_account_id }}:role/eks${{inputs.deploy-env}}adminrole-github
135137
aws-region: ${{ secrets.region }}
136138

137139
- name: Step 7 - Delete Logstash

.github/workflows/os-osd-deployment-scheduled.yml

+1
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ jobs:
3535
esnode_cert: ${{ secrets.ESNODE_CERT }}
3636
esnode_key_cert: ${{ secrets.ESNODE_KEY_CERT }}
3737
root_ca_cert: ${{ secrets.ROOT_CA_CERT }}
38+
aws_account_id: ${{ secrets.AWS_ACCOUNT_ID_PREVIEW }}
3839

3940
OSD-Functional-Test-Preview:
4041
needs: OS-OSD-Preview-Scheduled-Deployment

0 commit comments

Comments
 (0)