Modify pipeline and setenv
This commit is contained in:
@@ -94,13 +94,13 @@ definitions:
|
||||
allowed-values: # Optionally restrict variable values
|
||||
- "dev"
|
||||
- name: URL_DOMAIN
|
||||
default: dev01.dev-medicalalert.com
|
||||
default: dev01.dev-weareconnectamerica.com
|
||||
allowed-values: # Optionally restrict variable values
|
||||
- "dev01.dev-medicalalert.com"
|
||||
- "dev02.dev-medicalalert.com"
|
||||
- "dev03.dev-medicalalert.com"
|
||||
- "dev04.dev-medicalalert.com"
|
||||
- "dev05.dev-medicalalert.com"
|
||||
- "dev01.dev-weareconnectamerica.com"
|
||||
- "dev02.dev-weareconnectamerica.com"
|
||||
- "dev03.dev-weareconnectamerica.com"
|
||||
- "dev04.dev-weareconnectamerica.com"
|
||||
- "dev05.dev-weareconnectamerica.com"
|
||||
- name: MYSQL_FILE_NAME
|
||||
default: "MYSQL_FILE_NAME_TO_DEPLOY"
|
||||
- name: STATIC_FILE_NAME
|
||||
@@ -125,7 +125,7 @@ definitions:
|
||||
- git clone --branch="develop" https://x-token-auth:${cswtoken}@bitbucket.org/connectamerica/common-scripts-web.git && ls -lrth && cp -rf ./common-scripts-web/* . && ls -lrth
|
||||
- chmod 755 ./validation.sh && ./validation.sh default && echo validation-done || exit 9
|
||||
- ls -lrth && cd build/${ENV}
|
||||
- export DB_PASSWORD=$(aws ssm get-parameters --names $ENV-medicalalert-masterdbpass --query "Parameters[*].{Value:Value}" --output text)
|
||||
- export DB_PASSWORD=$(aws ssm get-parameters --names $ENV-weareconnectamerica-masterdbpass --query "Parameters[*].{Value:Value}" --output text)
|
||||
- export DB_PASSWORD=`echo -n "$DB_PASSWORD" | base64` && sed -i "/DB_PASSWORD/c\ DB_PASSWORD:\ $DB_PASSWORD" secrets.yaml
|
||||
- envsubst < deployment.tpl > deployment.yaml
|
||||
- cat deployment.yaml
|
||||
@@ -142,7 +142,7 @@ definitions:
|
||||
DEBUG: "true"
|
||||
after-script:
|
||||
- aws eks update-kubeconfig --name caresage-eks-cluster-$ENV --region us-east-1
|
||||
- sleep 10 && while kubectl get po -A |grep -i medicalalert-web|egrep -i '0/1|crash|term'; do sleep 10; echo "--- still getting 0/1 or crash pods-----"; done
|
||||
- sleep 10 && while kubectl get po -A |grep -i weareconnectamerica-web|egrep -i '0/1|crash|term'; do sleep 10; echo "--- still getting 0/1 or crash pods-----"; done
|
||||
|
||||
pipelines:
|
||||
# our custom pipeline, what shows up Bitbucket web app
|
||||
@@ -474,8 +474,8 @@ pipelines:
|
||||
#- chmod 755 ./validation.sh && ./validation.sh default
|
||||
- echo "make sure that release version file and plan has been added to the release repo"
|
||||
- source release
|
||||
- export MANIFEST=$(aws ecr batch-get-image --repository-name medicalalert-web --image-ids imageTag=$VERSION --output json | jq --raw-output --join-output '.images[0].imageManifest')
|
||||
- aws ecr put-image --repository-name medicalalert-web --image-tag $RELEASE --image-manifest "$MANIFEST" && echo ------ image $VERSION has been retagged as $RELEASE || exit 9
|
||||
- export MANIFEST=$(aws ecr batch-get-image --repository-name weareconnectamerica-web --image-ids imageTag=$VERSION --output json | jq --raw-output --join-output '.images[0].imageManifest')
|
||||
- aws ecr put-image --repository-name weareconnectamerica-web --image-tag $RELEASE --image-manifest "$MANIFEST" && echo ------ image $VERSION has been retagged as $RELEASE || exit 9
|
||||
- echo "export VERSION=$RELEASE" >> setenv.sh
|
||||
- echo "export ENV=stage" >> setenv.sh
|
||||
artifacts: # define the artifacts to be passed to each future step
|
||||
@@ -519,7 +519,7 @@ pipelines:
|
||||
- cp -rf ./common-scripts-web/* . && ls -lrth && export ENV=dev
|
||||
- chmod 755 ./validation.sh && ./validation.sh default
|
||||
|
||||
- export IMAGE="medicalalert-web" && export VERSION=$BITBUCKET_BUILD_NUMBER
|
||||
- export IMAGE="weareconnectamerica-web" && export VERSION=$BITBUCKET_BUILD_NUMBER
|
||||
- aws ecr get-login-password --region us-east-1 | docker login --username AWS --password-stdin 716593996126.dkr.ecr.us-east-1.amazonaws.com
|
||||
- docker build -t ${IMAGE} .
|
||||
- docker tag ${IMAGE} ${IMAGE}:${VERSION}
|
||||
|
||||
@@ -2,10 +2,9 @@
|
||||
|
||||
export REPO=$BITBUCKET_REPO_SLUG
|
||||
export CLUSTER=caresage-eks-cluster-$ENV
|
||||
export URL_DOMAIN=$SUBDOMAIN.$ENV-medicalalert.com
|
||||
export PROD_URL_DOMAIN=$SUBDOMAIN.medicalalert.com
|
||||
export PROD_FIND=medicalalert.com
|
||||
|
||||
export URL_DOMAIN=$SUBDOMAIN.$ENV-weareconnectamerica.com
|
||||
export PROD_URL_DOMAIN=$SUBDOMAIN.weareconnectamerica.com
|
||||
export PROD_FIND=weareconnectamerica.com
|
||||
|
||||
case $ENV in
|
||||
|
||||
@@ -16,7 +15,7 @@ case $ENV in
|
||||
stage)
|
||||
;;
|
||||
prod)
|
||||
export URL_DOMAIN=$SUBDOMAIN.medicalalert.com
|
||||
export URL_DOMAIN=$SUBDOMAIN.weareconnectamerica.com
|
||||
;;
|
||||
*)
|
||||
echo "source env varibales"
|
||||
|
||||
Reference in New Issue
Block a user