-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update buildspec: support 'make' commands
- Loading branch information
Showing
1 changed file
with
16 additions
and
11 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,39 @@ | ||
version: 0.2 | ||
|
||
env: | ||
secrets-manager: | ||
GITHUB_PRIVATE_KEY: "GITHUB_CREDENTIALS:PRIVATE_KEY" | ||
GITHUB_PUBLIC_KEY: "GITHUB_CREDENTIALS:PUBLIC_KEY" | ||
|
||
phases: | ||
install: | ||
runtime-versions: | ||
nodejs: 14 | ||
commands: | ||
# Copy keys for accessing GitHub (to download a fork of dynamodb-toolbox) | ||
- echo $GITHUB_PRIVATE_KEY | base64 --decode > ~/.ssh/id_ed25519 | ||
- echo $GITHUB_PUBLIC_KEY | base64 --decode > ~/.ssh/id_ed25519.pub | ||
- chmod 600 ~/.ssh/id_ed25519 | ||
- eval "$(ssh-agent -s)" | ||
|
||
# Upgrade npp to the latest version. Default version has a bug ('dist' folder is not downloaded in some cases). | ||
- npm install -g npm | ||
|
||
# Upgrade AWS CLI to the latest version | ||
- pip install --upgrade awscli | ||
|
||
# Install DynamoDbLocal image for running unit tests | ||
- docker run -p 8000:8000 -d public.ecr.aws/p7c5q3n4/amazon/dynamodb-local:latest | ||
- make install | ||
|
||
|
||
# Install all packages | ||
- make install | ||
|
||
pre_build: | ||
commands: | ||
- cd $CODEBUILD_SRC_DIR | ||
- make test | ||
|
||
|
||
build: | ||
commands: | ||
- cd $CODEBUILD_SRC_DIR | ||
- make deploy BUCKET_FOR_LAMBDAS=$BUCKET_FOR_LAMBDAS STAGE=$STAGE INTEGRATION_API_KEY=$INTEGRATION_API_KEY | ||
|
||
post_build: | ||
commands: | ||
|
||
artifacts: | ||
files: | ||
- template-export.yaml | ||
- product-catalog/template-export.yaml |