diff --git a/bitbucket-pipelines.yml b/bitbucket-pipelines.yml index 924072c..7518147 100644 --- a/bitbucket-pipelines.yml +++ b/bitbucket-pipelines.yml @@ -8,96 +8,94 @@ definitions: export AWS_SECRET_ACCESS_KEY=$(echo $STS_OUTPUT | jq -r '.Credentials.SecretAccessKey'); export AWS_SECURITY_TOKEN=$(echo $STS_OUTPUT | jq -r '.Credentials.SessionToken'); export AWS_REGION='us-east-2'; - stage: &deployment - trigger: manual - steps: - - step: - name: "Deploy Snowflake Changes" - image: python:3.7 - size: 2x - script: - - python -m pip install --upgrade pip - - pip install snowflake-connector-python - - pip install schemachange --upgrade - - echo $SNOWFLAKE_ACCOUNT $SNOWFLAKE_USER $SNOWFLAKE_ROLE $SNOWFLAKE_WAREHOUSE $SNOWFLAKE_DATABASE - - schemachange -a $SNOWFLAKE_ACCOUNT -u $SNOWFLAKE_USER -r $SNOWFLAKE_ROLE -w $SNOWFLAKE_WAREHOUSE -d $SNOWFLAKE_DATABASE -c $SNOWFLAKE_DATABASE.SCHEMACHANGE.CHANGE_HISTORY --create-change-history-table -v - caches: - - pip - #condition: - # changesets: - # includePaths: - # - snowflake/**/* - # - snowflake/**/**/* - # - snowflake/**/**/**/* - - step: - image: python:3.8 - name: "Deploy streamlit to EC2" - oidc: true - script: - - python -m pip install --upgrade pip - - apt-get update && apt-get install -y jq git - - pip install awscli - - *aws-context - - >- - aws ssm send-command --document-name "AWS-RunShellScript" --instance-ids $INSTANCE_ID_TF --region $AWS_DEFAULT_REGION --parameters commands='[ - "sudo -u ubuntu -i <- + aws ssm send-command --document-name "AWS-RunShellScript" --instance-ids $INSTANCE_ID_TF --region $AWS_DEFAULT_REGION --parameters commands='[ + "sudo -u ubuntu -i <