Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
12
5 changes: 3 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
# Enable container based builds
sudo: false
dist: focal
language: python

python:
- "3.7"
- "3.8"

install:
- nvm install
# Install the code requirements
- make init

Expand Down
6 changes: 3 additions & 3 deletions docs/user-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ pipelines:
account_id: 111112233332
build:
provider: codebuild
image: "STANDARD_2_0" # Use a specific docker image (defaults to Python 3.7) for the build stage in this pipeline -> https://docs.aws.amazon.com/cdk/api/latest/docs/@aws-cdk_aws-codebuild.LinuxBuildImage.html
image: "STANDARD_4_0" # Use a specific docker image (supports Python 3.7 and Python 3.8) for the build stage in this pipeline -> https://docs.aws.amazon.com/cdk/api/latest/docs/@aws-cdk_aws-codebuild.LinuxBuildImage.html
deploy:
provider: codedeploy
targets:
Expand Down Expand Up @@ -556,8 +556,8 @@ version: 0.2
phases:
install:
runtime-versions:
python: 3.7
nodejs: 10
python: 3.8
nodejs: 12
pre_build:
commands:
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
Expand Down
19 changes: 10 additions & 9 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
tox==2.2.1
pylint==2.2.2
pytest==3.0.7
isort==4.3.21
mock==2.0.0
boto3~=1.10, >=1.10.47
pyyaml>=5.1
astroid==2.1.0
schema==0.7.1
astroid~=2.4.2
botocore==1.17.63
boto3==1.14.63
isort==5.6.4
mock~=4.0.3
pylint~=2.6.0
pytest~=6.2.1
pyyaml>=5.3
schema~=0.7.2
tox==3.20.1
2 changes: 1 addition & 1 deletion samples/sample-cdk-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ This pipeline is expecting *(in the example case)* a AWS CodeCommit repository o
build:
provider: codebuild
properties:
image: "STANDARD_2_0"
image: "STANDARD_4_0"
targets:
- /banking/testing
- /banking/production
Expand Down
4 changes: 2 additions & 2 deletions samples/sample-cdk-app/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ version: 0.2
phases:
install:
runtime-versions:
python: 3.7
nodejs: 10
python: 3.8
nodejs: 12
commands:
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
- pip install -r adf-build/requirements.txt -q
Expand Down
2 changes: 1 addition & 1 deletion samples/sample-cdk-app/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export class LambdaCronStack extends cdk.Stack {
code: new lambda.InlineCode(fs.readFileSync('handler.py', { encoding: 'utf-8' })),
handler: 'index.main',
timeout: cdk.Duration.seconds(300),
runtime: lambda.Runtime.PYTHON_3_7
runtime: lambda.Runtime.PYTHON_3_8
});
// Run every day at 6PM UTC
// See https://docs.aws.amazon.com/lambda/latest/dg/tutorial-scheduled-events-schedule-expressions.html
Expand Down
2 changes: 1 addition & 1 deletion samples/sample-ec2-java-app-codedeploy/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ This example is coupled with the `sample-ec2-with-codedeploy` repository and is
build:
provider: codebuild
properties:
image: "STANDARD_2_0" # Since we're building a Java application here we want to use STANDARD_2_0 (Ubuntu) as our base CodeBuild Image, that way we can tell it to have Java ready for us so we can build, compile and test our application.
image: "STANDARD_4_0" # Since we're building a Java application here we want to use STANDARD_4_0 (Ubuntu) as our base CodeBuild Image, that way we can tell it to have Java ready for us so we can build, compile and test our application.
deploy:
provider: codedeploy # We will deploy out application with AWS CodeDeploy.
targets:
Expand Down
2 changes: 1 addition & 1 deletion samples/sample-ec2-java-app-codedeploy/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: 0.2
phases:
install:
runtime-versions:
java: openjdk8
java: corretto8
build:
commands:
- mvn clean package --quiet
Expand Down
4 changes: 4 additions & 0 deletions samples/sample-ec2-with-codedeploy/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ This stack also requires `sample-vpc` and `sample-iam` to be in deployed as it i
provider: codecommit
properties:
account_id: 111111111111
build:
provider: codebuild
properties:
image: "STANDARD_4_0" # So we can specify which Python version we need
targets:
- /banking/testing
- /banking/production
Expand Down
4 changes: 3 additions & 1 deletion samples/sample-ec2-with-codedeploy/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@ version: 0.2

phases:
install:
runtime-versions:
python: 3.8
commands:
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
- pip install -r adf-build/requirements.txt -q
- python adf-build/generate_params.py
artifacts:
files: '**/*'
files: '**/*'
4 changes: 4 additions & 0 deletions samples/sample-ecr-repository/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
provider: codecommit
properties:
account_id: 111111111111
build:
provider: codebuild
properties:
image: "STANDARD_4_0" # So we can specify which Python version we need
targets:
- /deployment
```
4 changes: 3 additions & 1 deletion samples/sample-ecr-repository/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@ version: 0.2

phases:
install:
runtime-versions:
python: 3.8
commands:
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
- pip install -r adf-build/requirements.txt -q
- python adf-build/generate_params.py
artifacts:
files: '**/*'
files: '**/*'
4 changes: 4 additions & 0 deletions samples/sample-ecs-cluster/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
provider: codecommit
properties:
account_id: 111111111111
build:
provider: codebuild
properties:
image: "STANDARD_4_0" # So we can specify which Python version we need
targets:
- 222222222222
- path: 333333333333
Expand Down
4 changes: 3 additions & 1 deletion samples/sample-ecs-cluster/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@ version: 0.2

phases:
install:
runtime-versions:
python: 3.8
commands:
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
- pip install -r adf-build/requirements.txt -q
- python adf-build/generate_params.py
artifacts:
files: '**/*'
files: '**/*'
2 changes: 2 additions & 0 deletions samples/sample-expunge-vpc/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,10 @@ Upon stack deletion the default VPCs will be recreated.
build:
provider: codebuild
properties:
image: "STANDARD_4_0" # So we can specify which Python version we need
environment_variables:
CONTAINS_TRANSFORM: true # Required for templates that contain transforms. (eg SAM Templates)

params:
- restart_execution_on_update: true
targets:
Expand Down
4 changes: 3 additions & 1 deletion samples/sample-expunge-vpc/buildspec.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
version: 0.2
phases:
install:
runtime-versions:
python: 3.8
commands:
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
- pip install -r adf-build/requirements.txt -q
Expand All @@ -9,4 +11,4 @@ phases:
commands:
- bash adf-build/helpers/package_transform.sh
artifacts:
files: "**/*"
files: "**/*"
4 changes: 2 additions & 2 deletions samples/sample-expunge-vpc/template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ Resources:
Handler: lambda_function.lambda_handler
MemorySize: 128
Role: !GetAtt LambdaVPCPolicyRole.Arn
Runtime: python3.7
Runtime: python3.8
Timeout: 600
Environment:
Variables:
region_name: !Ref "AWS::Region"
DeleteVPCCustom:
Type: Custom::DeleteVPC
Properties:
ServiceToken: !GetAtt DeleteVPCLambda.Arn
ServiceToken: !GetAtt DeleteVPCLambda.Arn
2 changes: 1 addition & 1 deletion samples/sample-fargate-node-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
build:
provider: codebuild
properties:
image: "STANDARD_2_0"
image: "STANDARD_4_0"
privileged: true # Required for Docker in Docker to work as expected (Since CodeBuild will run our docker commands to create and push our image)
targets: # Example Targets - These accounts/regions have had the sample-vpc deployed
- 222222222222
Expand Down
4 changes: 2 additions & 2 deletions samples/sample-fargate-node-app/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ phases:
install:
runtime-versions:
docker: 18
python: 3.7
python: 3.8
build:
commands:
- bash build/docker.sh
Expand All @@ -13,4 +13,4 @@ phases:
- bash build/generate_parameters.sh

artifacts:
files: '**/*'
files: '**/*'
4 changes: 4 additions & 0 deletions samples/sample-iam/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ This pipeline is expecting *(in the example case)* a AWS CodeCommit repository o
provider: codecommit
properties:
account_id: 111111111111
build:
provider: codebuild
properties:
image: "STANDARD_4_0"
params:
restart_execution_on_update: True
targets:
Expand Down
4 changes: 3 additions & 1 deletion samples/sample-iam/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@ version: 0.2

phases:
install:
runtime-versions:
python: 3.8
commands:
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
- pip install -r adf-build/requirements.txt -q
- python adf-build/generate_params.py
artifacts:
files: '**/*'
files: '**/*'
2 changes: 2 additions & 0 deletions samples/sample-mono-repo/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ repository.
build:
provider: codebuild
properties:
image: "STANDARD_4_0"
spec_filename: apps/alpha/buildspec.yml
deploy:
provider: cloudformation
Expand All @@ -52,6 +53,7 @@ repository.
build:
provider: codebuild
properties:
image: "STANDARD_4_0"
spec_filename: apps/beta/buildspec.yml
deploy:
provider: cloudformation
Expand Down
2 changes: 2 additions & 0 deletions samples/sample-mono-repo/apps/alpha/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ env:

phases:
install:
runtime-versions:
python: 3.8
commands:
- cd $INFRASTRUCTURE_ROOT_DIR
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
Expand Down
2 changes: 2 additions & 0 deletions samples/sample-mono-repo/apps/beta/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ env:

phases:
install:
runtime-versions:
python: 3.8
commands:
- cd $INFRASTRUCTURE_ROOT_DIR
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
Expand Down
3 changes: 2 additions & 1 deletion samples/sample-serverless-app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@
properties:
account_id: 111111111111
build:
provider: STANDARD_2_0
provider: codebuild
properties:
image: "STANDARD_4_0"
environment_variables:
CONTAINS_TRANSFORM: True
targets:
Expand Down
4 changes: 2 additions & 2 deletions samples/sample-serverless-app/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ version: 0.2
phases:
install:
runtime-versions:
python: 3.7
python: 3.8
build:
commands:
- bash build/generate_parameters.sh
- bash adf-build/helpers/package_transform.sh
artifacts:
files: '**/*'
files: '**/*'
4 changes: 2 additions & 2 deletions samples/sample-serverless-app/template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Resources:
Type: 'AWS::Serverless::Function'
Properties:
Handler: lambda_function.handler
Runtime: python3.7
Runtime: python3.8
CodeUri: .
Description: Sample Lambda Function
MemorySize: 128
Expand All @@ -21,4 +21,4 @@ Resources:
Type: Api
Properties:
Path: /resource/{id}
Method: get
Method: get
4 changes: 4 additions & 0 deletions samples/sample-service-catalog-product/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ This stack imports values from `sample-vpc` and `sample-iam`.
provider: codecommit
properties:
account_id: 111111111111
build:
provider: codebuild
properties:
image: "STANDARD_4_0"
targets:
- /banking/testing
- path: /banking/production
Expand Down
4 changes: 3 additions & 1 deletion samples/sample-service-catalog-product/buildspec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@ version: 0.2

phases:
install:
runtime-versions:
python: 3.8
commands:
- aws s3 cp s3://$S3_BUCKET_NAME/adf-build/ adf-build/ --recursive --quiet
- pip install -r adf-build/requirements.txt -q
- python adf-build/generate_params.py
artifacts:
files: '**/*'
files: '**/*'
2 changes: 1 addition & 1 deletion samples/sample-terraform/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
deploy:
provider: codebuild
properties:
image: "STANDARD_2_0"
image: "STANDARD_4_0"
targets:
- properties:
spec_filename: my_test_spec.yml
Expand Down
5 changes: 4 additions & 1 deletion samples/sample-terraform/my_test_spec.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ env:
TF_CLI_ARGS: "-no-color"

phases:
install:
runtime-versions:
python: 3.8
build:
commands:
- export PATH=$PATH:$(pwd)
Expand All @@ -20,4 +23,4 @@ phases:
- terraform validate
- bash adf-build/helpers/sts.sh $TF_VAR_TARGET_ACCOUNT_ID $TF_VAR_TARGET_ACCOUNT_ROLE
- terraform plan -out $ADF_PROJECT_NAME
- terraform apply $ADF_PROJECT_NAME
- terraform apply $ADF_PROJECT_NAME
Loading