diff --git a/chart/cohort/Chart.yaml b/chart/cohort/Chart.yaml index 59150255..8999f410 100644 --- a/chart/cohort/Chart.yaml +++ b/chart/cohort/Chart.yaml @@ -7,4 +7,4 @@ apiVersion: v1 appVersion: "1.0" description: Quality Measure and Cohort Service name: cohort -version: 0.1.0 +version: 1.0.0 diff --git a/pipeline.config b/pipeline.config index 60cab346..e618b5c1 100644 --- a/pipeline.config +++ b/pipeline.config @@ -3,6 +3,8 @@ # # SPDX-License-Identifier: Apache-2.0 # +# If you are deploying from the wh-cohorting-deploy umbrella repo, +# you will need to update this value with the Insights id from your cluster INSIGHTS: ID: "9b253889-dee0-47f4-9ea0-402306239aaa" CI: @@ -36,12 +38,15 @@ CD: # For a successful build to be promoted to Staging or Production, it is necessary to have an associated approved Service Now ticket. # The SERVICENOW_SERVICENAME value should match the "Configuration item" as defined in the servicenow change request. # See https://github.ibm.com/whc-toolchain/whc-commons/blob/2c9cfd2a3683dc5ba993d338f9fb0172165fb516/docs/launch/approval-gate.md - SERVICENOW_SERVICENAME: "wh-csp-core" + SERVICENOW_SERVICENAME: "offering-needs-to-change" TILLERSERVICEACCOUNTDISABLE: "true" HELM_TIMEOUT: "1800" USESOURCE: "true" USEHELMV3: "true" # See note about FHIR_CLUSTER_NAMESPACE above + # These keys are used by our full FVT tests which require a fhir server with specific test data loaded + # If you are deploying from the wh-cohorting-deploy umbrella repo, the full fvt tests have been removed + # and the vault keys are not required when deploying from that repo VAULT_KEYS_TO_INJECT: "FHIR_USER_PASSWORD,FHIR_TRUSTSTORE_PASSWD,FHIR_CLUSTER_NAMESPACE" # added to allow mixed case branch names (toolchains fail on mixed case branch names without this set, # could remove when we switch to using main branch diff --git a/prePromotion.sh b/prePromotion.sh new file mode 100644 index 00000000..1e004d1b --- /dev/null +++ b/prePromotion.sh @@ -0,0 +1,42 @@ +#Print commands and their arguments as they are executed. +set -x + +function readd_tests(){ + echo "./tests/run-tests.sh fvttest.xml" >>run-fvttests.sh + echo "./tests/run-tests.sh ivttest.xml" >>run-ivttests.sh + echo "./tests/run-tests.sh regtest.xml" >>run-regrtests.sh +} + +if [ "$UMBRELLA_REPO_PATH" == "https://github.ibm.com/watson-health-cohorting/wh-cohorting-umbrella" ]; then + if [ -f ./application.version ]; then + APPLICATION_VERSION="$(cat application.version)" + else + echo "There is not an application.version file" + exit 1 + fi + + echo "Validating versions are updated in the appropriate files" + APP_NAME='cohort-services' + COMPONENTNAME='cohort' + PATH_TO_COMPONENT="${APP_NAME}/${COMPONENTNAME}" + CHART_VERSION=$(cat "$PATH_TO_COMPONENT/chart/cohort/Chart.yaml" | grep 'version:' | sed -E 's/^version: (.+)$/\1/g') + if [ "$APPLICATION_VERSION" != "$CHART_VERSION" ]; then + echo "The chart version '$CHART_VERSION' does not match the application version '$APPLICATION_VERSION' you are releasing. Please make sure you have updated the helm chart version and the application.version file to match." + exit 1 + fi + + echo "Removing all unnecessary files except for smoke tests" + rm -f README.md +# rm -f mkdocs.yml + echo "Make README for wh-cohorting-deploy" + echo "# wh-cohorting-deploy + This repo is to assist teams in deployment to both CDT and CSP. For more information on deployments, see [(https://github.com/Alvearie/quality-measure-and-cohort-service#readme) Github readme." >>README.md + cd ./$PATH_TO_COMPONENT/tests/ + find . -not -name '*smoketest*' -not -name '*run-tests*' -not -name '*authenticate*' -not -path "./tests" -not -path "." >>remove_tests.txt + cat remove_tests.txt + xargs rm -rf " +date=`date` +header="" +footer="" + +filename=$1 +cat << EOF > $filename +$header +$output +$footer +EOF \ No newline at end of file