File tree Expand file tree Collapse file tree 2 files changed +10
-6
lines changed
Expand file tree Collapse file tree 2 files changed +10
-6
lines changed Original file line number Diff line number Diff line change 88
99jobs :
1010 build-and-test :
11- # Run on self-hosted runner inside the VPC
12- runs-on : [self-hosted, linux]
11+
12+ runs-on : [self-hosted, linux] # Runs inside your VPC for RDS access
13+
1314 steps :
1415 - name : Checkout code
1516 uses : actions/checkout@v3
2425
2526 - name : Run tests
2627 env :
27- DB_HOST : ${{ secrets.DB_HOST }} # RDS private endpoint
28+ # RDS private endpoint
29+
30+ DB_HOST : ${{ secrets.DB_HOST }}
2831 DB_USER : ${{ secrets.DB_USER }}
2932 DB_PASSWORD : ${{ secrets.DB_PASSWORD }}
3033 DB_NAME : ${{ secrets.DB_NAME }}
@@ -49,12 +52,12 @@ jobs:
4952 - name : Zip project
5053 run : zip -r function.zip .
5154
52- - name : Configure AWS credentials
55+ - name : Configure AWS credentials via OIDC
5356 uses : aws-actions/configure-aws-credentials@v2
5457 with :
55- aws-access-key-id : ${{ secrets.AWS_ACCESS_KEY_ID }}
56- aws-secret-access-key : ${{ secrets.AWS_SECRET_ACCESS_KEY }}
58+ role-to-assume : arn:aws:iam::011664843975:role/github-permissions
5759 aws-region : ${{ secrets.AWS_REGION }}
60+ role-session-name : github-actions-deploy
5861
5962 - name : Deploy Lambda with rollback
6063 id : deploy
Original file line number Diff line number Diff line change @@ -92,3 +92,4 @@ exports.handler = async (event) => {
9292 body : JSON . stringify ( body )
9393 } ;
9494} ;
95+
You can’t perform that action at this time.
0 commit comments