Commit b6885b63 authored by Matt Wise's avatar Matt Wise
Browse files

add schema deployment scripts to artifacts

parent b03541e7
......@@ -46,3 +46,6 @@ dist/
# Environment configuration
*.env
.envrc
# Python gen files
*.pyc
\ No newline at end of file
#Required Env Variables
#AWS_BASE_URL
#AWS_DEPLOYMENTS_SUBDIR
#AWS_REGION
#AWS_COGNITO_CLIENT_ID
#AWS_COGNITO_AUTH_FLOW
#AWS_COGNITO_AUTH_PARAMS_USER
#AWS_COGNITO_AUTH_PARAMS_PASSWORD
echo $AWS_BASE_URL
export AWS_SCHEMA_SERVICE_URL=$AWS_BASE_URL/api/schema-service/v1/schema
BEARER_TOKEN=`python $AWS_DEPLOYMENTS_SUBDIR/Token.py`
BEARER_TOKEN=`python3 $AWS_DEPLOYMENTS_SUBDIR/Token.py`
echo $BEARER_TOKEN
export BEARER_TOKEN=$BEARER_TOKEN
export APP_KEY=""
export DATA_PARTITION=common
python deployments/scripts/DeploySharedSchemas.py -l load_sequence.1.0.0.json -u $AWS_SCHEMA_SERVICE_URL
\ No newline at end of file
python3 deployments/scripts/DeploySharedSchemas.py -l load_sequence.1.0.0.json -u $AWS_SCHEMA_SERVICE_URL
\ No newline at end of file
# Copyright © 2021 Amazon Web Services
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# This script prepares the dist directory for the integration tests.
# Must be run from the root of the repostiory
# THIS SCRIPT MUST BE RUN FROM THE ROOT FOLDER OF THE SCHEMA SERVICE
set -e
OUTPUT_DIR="${OUTPUT_DIR:-dist}"
echo "--Copying Schema Boostrap Scripts to ${OUTPUT_DIR}--"
rm -rf "${OUTPUT_DIR}/deployments"
mkdir -p "${OUTPUT_DIR}/deployments"
rsync deployments/* "${OUTPUT_DIR}/deployments/"
cp -r deployments/shared-schemas/ "${OUTPUT_DIR}/deployments/shared-schemas/"
mkdir -p "${OUTPUT_DIR}/deployments/scripts/"
rsync deployments/scripts/* "${OUTPUT_DIR}/deployments/scripts/"
cp -r deployments/scripts/templates/ "${OUTPUT_DIR}/deployments/scripts/templates/"
cp -r deployments/scripts/aws/ "${OUTPUT_DIR}/deployments/scripts/aws/"
\ No newline at end of file
......@@ -70,6 +70,10 @@ phases:
- chmod +x ./testing/schema-test-aws/build-aws/prepare-dist.sh
- ./testing/schema-test-aws/build-aws/prepare-dist.sh
#Copy R3 data def bootstrap scripts to dist
- chmod +x ./deployments/scripts/aws/prepare-dist.sh
- ./deployments/scripts/aws/prepare-dist.sh
- echo "Logging into Docker Hub..."
- docker login -u ${DOCKER_USERNAME} -p ${DOCKER_PASSWORD}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment