Skip to content

Commit

Permalink
ci with github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
gmercyo committed Dec 26, 2023
1 parent 04f7f97 commit 2aea105
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Deploy to AWS Lambda

on:
push:
branches:
- main

jobs:
deploy:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.10'

- name: Install dependencies
run: |
pip install -r requirements.txt
- name: Deploy to AWS Lambda
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
run: |
zappa update dev
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
Flask==3.0.0
requests
python-dotenv
zappa
10 changes: 10 additions & 0 deletions zappa_settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"dev": {
"app_function": "app.app",
"aws_region": "us-east-2",
"profile_name": "default",
"project_name": "star-spotter-api",
"runtime": "python3.10",
"s3_bucket": "star-spotter"
}
}

0 comments on commit 2aea105

Please sign in to comment.