Skip to content

Merge pull request #65 from RapidAPI/add-env-param-to-lambda #259

Merge pull request #65 from RapidAPI/add-env-param-to-lambda

Merge pull request #65 from RapidAPI/add-env-param-to-lambda #259

name: Upload zip to lambdas in staging
on:
push:
branches:
- staging
jobs:
test-and-upload-to-staging:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: "v14.15.4"
- run: yarn install --frozen-lockfile
- run: yarn jest
- run: yarn check-format
- run: yarn lint
# Make zip
- uses: ./.github/actions/build-zip
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: actions/checkout@v2
# Default worker
- uses: ./.github/actions/upload-lambda
with:
worker_env: >
BASE_URL=https://rapidapi.xyz/testing,
LOCATION_CONTEXT=Default,
PREVENT_SELF_CALL=true,
LOCATION_KEY=AWS-STAGING,
LOCATION_SECRET=${{ secrets.LOCATION_SECRET_STAGING_DEFAULT }},
WORKER_LOGGING=cli,
POLLING_TIME_MAX=5000,
FREQUENCY=1000
aws_access_key_id: ${{ secrets.AWS_STAGING_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_STAGING_SECRET_ACCESS_KEY }}
aws_region: us-east-1
function_name: rapidapi-stage-testing-worker
# Custom worker
- uses: ./.github/actions/upload-lambda
with:
worker_env: >
BASE_URL=https://rapidapi.xyz/testing,
LOCATION_CONTEXT=3799087,
PREVENT_SELF_CALL=true,
LOCATION_KEY=custom-staging-worker,
LOCATION_SECRET=${{ secrets.LOCATION_SECRET_STAGING_CUSTOM }},
POLLING_TIME_MAX=70000,
FREQUENCY=2000,
WORKER_LOGGING=cli
aws_access_key_id: ${{ secrets.AWS_STAGING_ACCESS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_STAGING_SECRET_ACCESS_KEY }}
aws_region: us-east-1
function_name: rapidapi-stage-testing-worker-custom