diff --git a/ci/docker-deployment-tests.sh b/ci/docker-deployment-tests.sh index 341a22d82..35b9060d3 100755 --- a/ci/docker-deployment-tests.sh +++ b/ci/docker-deployment-tests.sh @@ -3,7 +3,7 @@ set -ex # find the dir two levels up from here, home of all the repositories -COMPUTED_ROOT=$(readlink -e $(dirname "$0")/../../) +COMPUTED_ROOT="$(readlink -e "$(dirname "$0")/../../")" # NTECH_ROOT should be the same, but if available use it so user can do their own thing. NTECH_ROOT=${NTECH_ROOT:-$COMPUTED_ROOT} diff --git a/ci/package-sha.sh b/ci/package-sha.sh index 802f377cb..6812fab89 100755 --- a/ci/package-sha.sh +++ b/ci/package-sha.sh @@ -2,7 +2,7 @@ set -e # find the dir two levels up from here, home of all the repositories -COMPUTED_ROOT=$(readlink -e $(dirname "$0")/../../) +COMPUTED_ROOT="$(readlink -e "$(dirname "$0")/../../")" # NTECH_ROOT should be the same, but if available use it so user can do their own thing. NTECH_ROOT=${NTECH_ROOT:-$COMPUTED_ROOT} @@ -14,5 +14,5 @@ MASTERFILES_SHA=$(git -C "${NTECH_ROOT}/masterfiles" log --pretty='format:%h' -1 MISSION_PORTAL_SHA=$(find "${NTECH_ROOT}/mission-portal" -type f -and \( -path "./application/*" -or -path "./public/*" -or -path "./phpcfenginenova/*" -or -path "./ldap/*" -or -path "./composer.json" -or -path "./package.json" -or -path "./static/*" \) -print0 | xargs -0 sha1sum | awk '{print $1}' | sha1sum | cut -c -8) BUILDSCRIPTS_SHA=$(find "${NTECH_ROOT}/buildscripts" -type f -and \( -path "./deps-packaging/*" -or -path "./build-scripts/*" -or -path "./packaging/*" \) -print0 | xargs -0 sha1sum | awk '{print $1}' | sha1sum | cut -c -8) -PACKAGE_SHA=$(echo $CORE_SHA $ENTERPRISE_SHA $NOVA_SHA $MASTERFILES_SHA $MISSION_PORTAL_SHA $BUILDSCRIPTS_SHA | sha256sum | cut -d' ' -f1 | cut -c -8) -echo $PACKAGE_SHA +PACKAGE_SHA=$(echo "$CORE_SHA" "$ENTERPRISE_SHA" "$NOVA_SHA" "$MASTERFILES_SHA" "$MISSION_PORTAL_SHA" "$BUILDSCRIPTS_SHA" | sha256sum | cut -d' ' -f1 | cut -c -8) +echo "$PACKAGE_SHA"