Created
May 17, 2018 16:20
-
-
Save thoughtspeed7/7d4b349385213d8d0f09967943281a60 to your computer and use it in GitHub Desktop.
CI / CD for AWS Lambda using GCP's Container Builder and Bitbucket!
This file contains hidden or 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
| # om namah shivay | |
| secrets: | |
| - kmsKeyName: projects/[PROJECT_ID]/locations/global/keyRings/[KEY_RING_NAME]/cryptoKeys/[KEY_NAME] | |
| secretEnv: | |
| AWS_ACCESS_KEY_ID: [BASE_64_ENCRYPTED_AWS_ACCESS_KEY_ID] | |
| AWS_SECRET_ACCESS_KEY: [BASE_64_ENCRYPTED_AWS_SECRET_ACCESS_KEY] | |
| steps: | |
| # zip the source code | |
| - name: gcr.io/$PROJECT_ID/aws-cli | |
| args: | |
| - zip | |
| - -r | |
| - hello-world.zip | |
| - . | |
| dir: /workspace | |
| # deploy the function | |
| - name: gcr.io/$PROJECT_ID/aws-cli | |
| args: | |
| - aws | |
| - lambda | |
| - update-function-code | |
| - --function-name | |
| - hello-world | |
| - --zip-file | |
| - fileb://hello-world.zip | |
| env: | |
| - AWS_DEFAULT_REGION=us-east-1 | |
| secretEnv: | |
| - AWS_ACCESS_KEY_ID | |
| - AWS_SECRET_ACCESS_KEY |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment