Skip to content

Commit

Permalink
Merge pull request #45 from anthonywritescode/build-and-deploy
Browse files Browse the repository at this point in the history
add workflow to build and deploy lambda
  • Loading branch information
asottile authored Sep 4, 2023
2 parents dd19c4b + 8c7bbd8 commit 7c0a3b4
Showing 1 changed file with 26 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
on:
pull_request:
push:
branches: [main, test-me-*]

jobs:
main:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.x
- run: pip install cargo-lambda
- uses: actions-rust-lang/setup-rust-toolchain@v1
- run: cargo lambda build --release --output-format zip
- uses: aws-actions/[email protected]
with:
role-to-assume: 'arn:aws:iam::048899320783:role/awc_wideo_bot_deploy'
aws-region: us-east-1
if: github.event_name == 'push'
- run: |
aws lambda \
update-function-code --function-name awc_wideo_bot \
--zip fileb://target/lambda/awc-wideo-bot/bootstrap.zip
if: github.event_name == 'push'

0 comments on commit 7c0a3b4

Please sign in to comment.