@@ -70,22 +70,31 @@ get_vrel_from_rpm() {
7070
7171# The current release version (e.g. '4.17') affects
7272# the definition of previous and fake next versions.
73- export MAJOR_VERSION=4
74- export MINOR_VERSION=22
73+ export MAJOR_VERSION=5
74+ export MINOR_VERSION=0
7575export PREVIOUS_MAJOR_VERSION=4
76- export PREVIOUS_MINOR_VERSION=21
76+ export PREVIOUS_MINOR_VERSION=22
7777export YMINUS2_MAJOR_VERSION=4
78- export YMINUS2_MINOR_VERSION=20
79- export FAKE_NEXT_MINOR_VERSION=$(( "${MINOR_VERSION} " + 1 ))
78+ export YMINUS2_MINOR_VERSION=21
79+ # Handle cross-major version boundary (e.g. 4.22 -> 5.0)
80+ declare -A LAST_MINOR_FOR_MAJOR=([4]=22)
81+ if [[ -n " ${LAST_MINOR_FOR_MAJOR[${MAJOR_VERSION}]:- } " && \
82+ " ${MINOR_VERSION} " -eq " ${LAST_MINOR_FOR_MAJOR[${MAJOR_VERSION}]} " ]]; then
83+ export FAKE_NEXT_MAJOR_VERSION=$(( MAJOR_VERSION + 1 ))
84+ export FAKE_NEXT_MINOR_VERSION=0
85+ else
86+ export FAKE_NEXT_MAJOR_VERSION=" ${MAJOR_VERSION} "
87+ export FAKE_NEXT_MINOR_VERSION=$(( "${MINOR_VERSION} " + 1 ))
88+ fi
8089
8190# For a main branch, the current release repository usually comes from
8291# the OpenShift mirror site, either 'ocp-dev-preview' in the beginning of the
8392# development cycle or 'ocp' when release candidates are built regularly.
8493#
8594# For a release branch, the current release repository should come from the
8695# official 'rhocp' stream.
87- CURRENT_RELEASE_REPO=" https://mirror.openshift.com/pub/openshift-v4/ ${UNAME_M} /microshift/ocp-dev-preview/latest-4.22/el9/os "
88- CURRENT_RELEASE_VERSION=" $( get_vrel_from_beta " ${CURRENT_RELEASE_REPO} " ) "
96+ CURRENT_RELEASE_REPO=" "
97+ CURRENT_RELEASE_VERSION=" "
8998export CURRENT_RELEASE_REPO
9099export CURRENT_RELEASE_VERSION
91100
@@ -100,15 +109,15 @@ export CURRENT_RELEASE_VERSION
100109# For a release branch, the previous release repository should come from the
101110# official 'rhocp' stream.# The previous release repository value should either
102111# point to the OpenShift mirror URL or the 'rhocp' repository name.
103- PREVIOUS_RELEASE_REPO=" rhocp-4.21-for-rhel-9- ${UNAME_M} -rpms "
104- PREVIOUS_RELEASE_VERSION=" $( get_vrel_from_rhsm " ${PREVIOUS_RELEASE_REPO} " ) "
112+ PREVIOUS_RELEASE_REPO=" https://mirror.openshift.com/pub/openshift-v4/ ${UNAME_M} /microshift/ocp-dev-preview/latest-4.22/el9/os "
113+ PREVIOUS_RELEASE_VERSION=" $( get_vrel_from_beta " ${PREVIOUS_RELEASE_REPO} " ) "
105114export PREVIOUS_RELEASE_REPO
106115export PREVIOUS_RELEASE_VERSION
107116
108117# The y-2 release repository value should either point to the OpenShift
109118# mirror URL or the 'rhocp' repository name. It should always come from
110119# the 'rhocp' stream.
111- YMINUS2_RELEASE_REPO=" rhocp-4.20 -for-rhel-9-${UNAME_M} -rpms"
120+ YMINUS2_RELEASE_REPO=" rhocp-4.21 -for-rhel-9-${UNAME_M} -rpms"
112121YMINUS2_RELEASE_VERSION=" $( get_vrel_from_rhsm " ${YMINUS2_RELEASE_REPO} " ) "
113122export YMINUS2_RELEASE_REPO
114123export YMINUS2_RELEASE_VERSION
@@ -129,19 +138,19 @@ export RHOCP_MINOR_Y_BETA
129138# The 'rhocp_major_y1' and 'rhocp_minor_y1' variables should be the previous major
130139# and minor version numbers, if the previous release is available through the
131140# 'rhocp' stream, otherwise empty.
132- RHOCP_MAJOR_Y1=4
133- RHOCP_MINOR_Y1=21
141+ RHOCP_MAJOR_Y1=" "
142+ RHOCP_MINOR_Y1=" "
134143# The beta repository, containing dependencies, should point to the
135144# OpenShift mirror URL. The mirror for previous release should always
136145# be available.
137- RHOCP_MINOR_Y1_BETA=" https://mirror.openshift.com/pub/openshift-v4/${UNAME_M} /dependencies/rpms/4.21 -el9-beta"
146+ RHOCP_MINOR_Y1_BETA=" https://mirror.openshift.com/pub/openshift-v4/${UNAME_M} /dependencies/rpms/4.22 -el9-beta"
138147export RHOCP_MAJOR_Y1
139148export RHOCP_MINOR_Y1
140149export RHOCP_MINOR_Y1_BETA
141150
142151# The 'rhocp_major_y2' and 'rhocp_minor_y2' should always be the y-2 version numbers.
143152export RHOCP_MAJOR_Y2=4
144- export RHOCP_MINOR_Y2=20
153+ export RHOCP_MINOR_Y2=21
145154
146155export CNCF_SONOBUOY_VERSION=v0.57.3
147156
0 commit comments