Skip to content

Commit eb819eb

Browse files
donoghucyaauie
authored andcommitted
Ensure observabilitySRE image is pushed on DRA staging (#17569)
The `artifactDockerObservabilitySRE` gradle task *always* produces a tag with a `SNAPSHOT` postfix. In the staging pipeline we use the shared `qualified-version` script for determining the LS version. That script correctly handles conditionally adding a `SNAPSHOT` postfix which is important for the tagging scheme for pushing to our container registry. Given the intermediate tag produced by the gradle task is never pushed anywhere we can update the build script to ensure the "local" artifact is always referenced with the `SNAPSHOT` postfix.
1 parent d0b105f commit eb819eb

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

.buildkite/scripts/dra/build-and-push-observability-sre.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,12 @@ echo "Pushing ObservabilitySRE container to Docker repository"
1717
docker_login
1818

1919
# Get qualified version without SHA (this is what the gradle task will produce)
20+
# Note that the gradle task always produces a version with -SNAPSHOT so if the
21+
# workflow type is staging we need to append -SNAPSHOT to the version.
2022
QUALIFIED_VERSION="$(.buildkite/scripts/common/qualified-version.sh)"
23+
if [[ "${WORKFLOW_TYPE:-}" == "staging" && "${QUALIFIED_VERSION}" != *-SNAPSHOT ]]; then
24+
QUALIFIED_VERSION="${QUALIFIED_VERSION}-SNAPSHOT"
25+
fi
2126

2227
# Set environment variable to include SHA and get version with SHA
2328
QUALIFIED_VERSION_WITH_SHA="$(INCLUDE_COMMIT_ID=1 .buildkite/scripts/common/qualified-version.sh)"

0 commit comments

Comments
 (0)