Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -207,11 +207,15 @@ jobs:
- export DIST=el8
- export OS=rocky8
- export BES_REPO_DIR=${TRAVIS_BUILD_DIR}
# Note: We use `source` instead of `bash` here so that we
# have downstream access to the environment variable
# `BUILD_VERSION_TAG` that must be exported AFTER the image
- ${TRAVIS_BUILD_DIR}/travis/build-rhel-docker.sh
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The file travis/build-rhel-docker.sh needs its permission changed to be an executable.

# Note: We need downstream access to the environment variable
# `BUILD_VERSION_TAG` that can only be determined AFTER the image
# is built:
- source ${TRAVIS_BUILD_DIR}/travis/build-rhel-docker.sh
- |
export BES_VERSION="$(docker run --rm ${SNAPSHOT_IMAGE_TAG} -c 'cat bes_VERSION')"
export BUILD_VERSION_TAG="opendap/${DOCKER_NAME}:${BES_VERSION}"
echo "Tagging image with BES version: ${BUILD_VERSION_TAG}"
docker tag ${SNAPSHOT_IMAGE_TAG} ${BUILD_VERSION_TAG}

- stage: build-and-package
name: "dist"
Expand Down
11 changes: 0 additions & 11 deletions travis/build-rhel-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -89,15 +89,4 @@ docker build \
echo "Docker build complete!"
docker image ls -a

loggy "Tagging the image with its version number..."
export BES_VERSION="$(docker run --rm ${SNAPSHOT_IMAGE_TAG} -c 'cat bes_VERSION')"
echo "BES_VERSION is ${BES_VERSION}"
export BUILD_VERSION_TAG="opendap/${DOCKER_NAME}:${BES_VERSION}"
echo "BUILD_VERSION_TAG is ${BUILD_VERSION_TAG}"
docker tag ${SNAPSHOT_IMAGE_TAG} ${BUILD_VERSION_TAG}

loggy "Complete!"

# Because this script is often sourced (at least by travis),
# unset these commands to prevent spurious downstream failures
set +eux
Loading