Deploy Staging Lambda Function #4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy Staging Lambda Function | |
on: | |
workflow_dispatch: | |
jobs: | |
deploy_lambda: | |
runs-on: ubuntu-latest | |
defaults: | |
run: | |
working-directory: ./kinesis-to-http | |
name: Deploy staging lambda | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Configure AWS Credentials | |
uses: aws-actions/configure-aws-credentials@v2 | |
with: | |
aws-access-key-id: ${{ secrets.LAMBDA_AWS_ACCESS_KEY_ID }} | |
aws-secret-access-key: ${{ secrets.LAMBDA_AWS_SECRET_ACCESS_KEY }} | |
aws-region: us-east-1 | |
role-session-name: lambda-deploy-staging | |
- name: Install dependencies | |
run: | | |
pip install --target . requests | |
- name: Zip package | |
run: | | |
zip -r ./lambda.zip . | |
- name: AWS Deploy | |
run: | | |
aws lambda update-function-code \ | |
--function-name eras-forwarder-staging \ | |
--zip-file fileb://lambda.zip |