version: 0.2 phases: install: runtime-versions: python: 3.8 java: corretto8 pre_build: commands: - pip install aws-sam-cli build: commands: - cd $CODEBUILD_SRC_DIR - cd java-app-backend - sam build -t template.yaml - sam package --template-file .aws-sam/build/template.yaml --s3-prefix web-app --s3-bucket $PACKAGE_BUCKET --output-template-file packaged-template.yml artifacts: discard-paths: yes files: - java-app-backend/packaged-template.yml