From 211c358e9e603aef56e1b2ccdbfd03345b66c0c3 Mon Sep 17 00:00:00 2001 From: Mirza Dautbegovic Date: Tue, 12 Nov 2019 17:58:05 +0100 Subject: [PATCH] Create buildspec.yml --- buildspec.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 buildspec.yml diff --git a/buildspec.yml b/buildspec.yml new file mode 100644 index 000000000..7606dd7c5 --- /dev/null +++ b/buildspec.yml @@ -0,0 +1,27 @@ +version: 0.2 + +phases: + install: + runtime-versions: + java: openjdk8 + commands: + # Upgrade AWS CLI to the latest version + - pip install --upgrade awscli + pre_build: + commands: + - mvn clean compile test + build: + commands: + - mvn war:exploded + post_build: + commands: + - cp -r .ebextensions/ target/ROOT/ + # aws cloudformation package --template template.yml --s3-bucket $S3_BUCKET --output-template-file template-export.yml + # Do not remove this statement. This command is required for AWS CodeStar projects. + # Update the AWS Partition, AWS Region, account ID and project ID in the project ARN on template-configuration.json file so AWS CloudFormation can tag project resources. + #sed -i.bak 's/\$PARTITION\$/'${PARTITION}'/g;s/\$AWS_REGION\$/'${AWS_REGION}'/g;s/\$ACCOUNT_ID\$/'${ACCOUNT_ID}'/g;s/\$PROJECT_ID\$/'${PROJECT_ID}'/g' template-configuration.json +artifacts: + type: zip + files: + - 'template-export.yml' + - 'template-configuration.json'