Fix GITLAB vars

This commit is contained in:
Gerald Pinder
2023-07-23 13:19:31 -04:00
parent abe70c97db
commit ab309ca512

View File

@@ -14,16 +14,15 @@ default:
COMMIT_TAGS=()
BUILD_TAGS=()
# Have tags for tracking builds during pull request
SHA_SHORT="$CI_COMMIT_SHA"
COMMIT_TAGS+=("pr-${{ github.event.number }}-${FEDORA_MAJOR_VERSION}")
COMMIT_TAGS+=("${SHA_SHORT}-${FEDORA_MAJOR_VERSION}")
COMMIT_TAGS+=("pr-${CI_MERGE_REQUEST_IID}-${FEDORA_MAJOR_VERSION}")
COMMIT_TAGS+=("${CI_COMMIT_SHORT_SHA}-${FEDORA_MAJOR_VERSION}")
BUILD_TAGS=("${FEDORA_MAJOR_VERSION}" "${FEDORA_MAJOR_VERSION}-${TIMESTAMP}")
BUILD_TAGS+=("${TIMESTAMP}")
BUILD_TAGS+=("latest")
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
if [[ $CI_PIPELINE_SOURCE == "merge_request_event" ]]; then
echo "Generated the following commit tags: "
for TAG in "${COMMIT_TAGS[@]}"; do
echo "${TAG}"