Skip to content

Commit 3a07cf8

Browse files
author
Ash
committed
Add GitHub Actions CI/CD pipeline
1 parent c6a096b commit 3a07cf8

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

.github/workflows/deploy.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Deploy CDK Python Lambda
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
deploy:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/checkout@v4
14+
15+
- name: Setup Node.js
16+
uses: actions/setup-node@v4
17+
with:
18+
node-version: 20
19+
20+
- name: Setup Python
21+
uses: actions/setup-python@v5
22+
with:
23+
python-version: '3.11'
24+
25+
- name: Install Python dependencies
26+
run: pip install -r requirements.txt
27+
28+
- name: Install AWS CDK
29+
run: npm install -g aws-cdk
30+
31+
- name: Deploy CDK stack
32+
run: cdk deploy --require-approval never
33+
env:
34+
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
35+
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
36+
AWS_REGION: ap-south-1

0 commit comments

Comments
 (0)