Skip to content

Instantly share code, notes, and snippets.

@PrashantBhatasana
Last active December 24, 2019 13:19
Show Gist options
  • Save PrashantBhatasana/54d37149c9dc9b13fabf8a4e4075cadb to your computer and use it in GitHub Desktop.
Save PrashantBhatasana/54d37149c9dc9b13fabf8a4e4075cadb to your computer and use it in GitHub Desktop.
This is the bitbucket pipelines yml file.
image: lambci/lambda:build-nodejs6.10
pipelines:
default:
- step:
name: Build and package
script:
- apt-get update && apt-get install -y zip
- npm install
- npm install node-lambda -g
- zip -r code.zip ./node_modules handler.js package.json
artifacts:
- code.zip
- step:
name: Update Lambda code
script:
- pipe: atlassian/aws-lambda-deploy:0.4.3
variables:
AWS_ACCESS_KEY_ID: ${AWS_ACCESS_KEY_ID}
AWS_SECRET_ACCESS_KEY: ${AWS_SECRET_KEY_ID}
AWS_DEFAULT_REGION: 'us-east-2'
FUNCTION_NAME: '<FUNCTION_NAME>'
COMMAND: 'deploy'
ZIP_FILE: 'code.zip'
caches:
- node
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment