diff --git a/scripts/app_deployment.sh b/scripts/app_deployment.sh index 897d4ab..bfd067f 100755 --- a/scripts/app_deployment.sh +++ b/scripts/app_deployment.sh @@ -1,8 +1,17 @@ -#! /bin/bash - #exits program immediately if a command is not sucessful set -e +if [ -z "$1" ]; then + echo "Missing commit message arguement 1" + exit 1 +fi + + +git add -A + +git commit -m "$1" + + export PROJECT_NAME="tvratings" export BUCKET_NAME="${PROJECT_NAME}-app-artifacts" export DEPLOYMENT_PACKAGE="${PROJECT_NAME}_deployment_package.zip" @@ -50,5 +59,14 @@ deactivate git push origin dev +echo "pushed to remote" + +gh pr create --title "$1" \ +--body "Automated PR creation" \ +--head dev \ +--base master + +echo "created PR" + echo "----------------------" echo "deployment successful" \ No newline at end of file diff --git a/templates/ask_lambda_layer.template b/templates/alexa_skills_kit_sdk_python_layer.template similarity index 68% rename from templates/ask_lambda_layer.template rename to templates/alexa_skills_kit_sdk_python_layer.template index 46e4e9a..f59ed7f 100644 --- a/templates/ask_lambda_layer.template +++ b/templates/alexa_skills_kit_sdk_python_layer.template @@ -23,27 +23,7 @@ Parameters: Type: String Default: lambda-deployment-bundles - oldLayerBucketKey: - Type: String - Default: ask_layer.zip - - oldLayerBucketName: - Type: String - Default: burnday-app-artifacts - - Resources: - askPythonLayer: - Type: AWS::Lambda::LayerVersion - Properties: - CompatibleRuntimes: - - python3.9 - Content: - S3Bucket: !Ref oldLayerBucketName - S3Key: !Ref oldLayerBucketKey - Description: Alexa Skills kit python sdk for v1.16.1 - LayerName: ask-core-1-16-1 - askMostRecentPython311: Type: AWS::Lambda::LayerVersion