Skip to content

Commit 6b00ac3

Browse files
committed
config: add periodic job that runs upgrades using multistage tests
1 parent ea02b4f commit 6b00ac3

File tree

9 files changed

+147
-12
lines changed

9 files changed

+147
-12
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
releases:
2+
initial:
3+
release:
4+
channel: stable
5+
version: "4.4"
6+
latest:
7+
candidate:
8+
product: ocp
9+
stream: ci
10+
version: "4.5"
11+
resources:
12+
'*':
13+
requests:
14+
cpu: 100m
15+
memory: 200Mi
16+
tests:
17+
- as: e2e-upgrade-informer
18+
cron: 0 */6 * * *
19+
steps:
20+
cluster_profile: aws
21+
env:
22+
OPENSHIFT_UPGRADE: "true"
23+
workflow: openshift-e2e-aws
24+
zz_generated_metadata:
25+
branch: master
26+
org: openshift
27+
repo: release
28+
variant: ocp-4.5-ci

ci-operator/jobs/openshift/release/openshift-release-master-periodics.yaml

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,87 @@ periodics:
248248
- name: result-aggregator
249249
secret:
250250
secretName: result-aggregator
251+
- agent: kubernetes
252+
cluster: api.ci
253+
cron: 0 */6 * * *
254+
decorate: true
255+
decoration_config:
256+
skip_cloning: true
257+
extra_refs:
258+
- base_ref: master
259+
org: openshift
260+
repo: release
261+
labels:
262+
ci-operator.openshift.io/prowgen-controlled: "true"
263+
ci-operator.openshift.io/variant: ocp-4.5-ci
264+
pj-rehearse.openshift.io/can-be-rehearsed: "true"
265+
name: periodic-ci-openshift-release-master-ocp-4.5-ci-e2e-upgrade-informer
266+
spec:
267+
containers:
268+
- args:
269+
- --image-import-pull-secret=/etc/pull-secret/.dockerconfigjson
270+
- --kubeconfig=/etc/apici/kubeconfig
271+
- --lease-server-password-file=/etc/boskos/password
272+
- --report-password-file=/etc/report/password.txt
273+
- --report-username=ci
274+
- --secret-dir=/secrets/ci-pull-credentials
275+
- --secret-dir=/usr/local/e2e-upgrade-informer-cluster-profile
276+
- --target=e2e-upgrade-informer
277+
- --variant=ocp-4.5-ci
278+
command:
279+
- ci-operator
280+
image: ci-operator:latest
281+
imagePullPolicy: Always
282+
name: ""
283+
resources:
284+
requests:
285+
cpu: 10m
286+
volumeMounts:
287+
- mountPath: /etc/apici
288+
name: apici-ci-operator-credentials
289+
readOnly: true
290+
- mountPath: /etc/boskos
291+
name: boskos
292+
readOnly: true
293+
- mountPath: /secrets/ci-pull-credentials
294+
name: ci-pull-credentials
295+
readOnly: true
296+
- mountPath: /usr/local/e2e-upgrade-informer-cluster-profile
297+
name: cluster-profile
298+
- mountPath: /etc/pull-secret
299+
name: pull-secret
300+
readOnly: true
301+
- mountPath: /etc/report
302+
name: result-aggregator
303+
readOnly: true
304+
serviceAccountName: ci-operator
305+
volumes:
306+
- name: apici-ci-operator-credentials
307+
secret:
308+
items:
309+
- key: sa.ci-operator.apici.config
310+
path: kubeconfig
311+
secretName: apici-ci-operator-credentials
312+
- name: boskos
313+
secret:
314+
items:
315+
- key: password
316+
path: password
317+
secretName: boskos-credentials
318+
- name: ci-pull-credentials
319+
secret:
320+
secretName: ci-pull-credentials
321+
- name: cluster-profile
322+
projected:
323+
sources:
324+
- secret:
325+
name: cluster-secrets-aws
326+
- name: pull-secret
327+
secret:
328+
secretName: regcred
329+
- name: result-aggregator
330+
secret:
331+
secretName: result-aggregator
251332
- agent: kubernetes
252333
cluster: api.ci
253334
cron: 0 0 * * 1

ci-operator/step-registry/ipi/conf/aws/ipi-conf-aws-ref.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
ref:
22
as: ipi-conf-aws
3-
from: base
3+
from_image:
4+
namespace: origin
5+
name: centos
6+
tag: '8'
47
commands: ipi-conf-aws-commands.sh
58
resources:
69
requests:

ci-operator/step-registry/ipi/conf/ipi-conf-commands.sh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@ if [[ -z "$RELEASE_IMAGE_LATEST" ]]; then
1313
exit 1
1414
fi
1515

16-
echo "Installing from release ${RELEASE_IMAGE_LATEST}"
17-
1816
ssh_pub_key=$(<"${CLUSTER_PROFILE_DIR}/ssh-publickey")
1917
pull_secret=$(<"${CLUSTER_PROFILE_DIR}/pull-secret")
2018

ci-operator/step-registry/ipi/conf/ipi-conf-ref.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
ref:
22
as: ipi-conf
3-
from: base
3+
from_image:
4+
namespace: origin
5+
name: centos
6+
tag: '8'
47
commands: ipi-conf-commands.sh
58
resources:
69
requests:

ci-operator/step-registry/ipi/install/install/ipi-install-install-commands.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,12 @@ fi
1313

1414
export SSH_PRIV_KEY_PATH=${CLUSTER_PROFILE_DIR}/ssh-privatekey
1515
export PULL_SECRET_PATH=${CLUSTER_PROFILE_DIR}/pull-secret
16-
export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=${RELEASE_IMAGE_LATEST}
16+
if [[ "${OPENSHIFT_UPGRADE:-false}" == "false" ]]; then
17+
export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=${RELEASE_IMAGE_LATEST}
18+
else
19+
export OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE=${RELEASE_IMAGE_INITIAL}
20+
fi
21+
echo "Installing from release ${OPENSHIFT_INSTALL_RELEASE_IMAGE_OVERRIDE}"
1722
export OPENSHIFT_INSTALL_INVOKER=openshift-internal-ci/${JOB_NAME}/${BUILD_ID}
1823
export HOME=/tmp
1924

ci-operator/step-registry/ipi/install/install/ipi-install-install-ref.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,8 @@ ref:
66
requests:
77
cpu: 1000m
88
memory: 2Gi
9+
env:
10+
- name: OPENSHIFT_UPGRADE
11+
default: "false"
912
documentation: |-
1013
The IPI install step runs the OpenShift Installer in order to bring up an OpenShift cluster, using the provided cluster profile to choose a target IaaS platform. Anything that needs to be configured using manifests should generate them before this step and put them in the SHARED_DIR with the filename manifest_(manifest_name).yml so that this step can pull in the manifest in.

ci-operator/step-registry/openshift/e2e/test/openshift-e2e-test-commands.sh

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -62,12 +62,23 @@ if [[ "${CLUSTER_TYPE}" == gcp ]]; then
6262
popd
6363
fi
6464

65-
test_suite=openshift/conformance/parallel
66-
if [[ -e "${SHARED_DIR}/test-suite.txt" ]]; then
67-
test_suite=$(<"${SHARED_DIR}/test-suite.txt")
68-
fi
69-
70-
openshift-tests run "${test_suite}" \
71-
--provider "${TEST_PROVIDER}" \
65+
if [[ "${OPENSHIFT_UPGRADE:-false}" == "false" ]]; then
66+
test_suite=openshift/conformance/parallel
67+
if [[ -e "${SHARED_DIR}/test-suite.txt" ]]; then
68+
test_suite=$(<"${SHARED_DIR}/test-suite.txt")
69+
fi
70+
openshift-tests run "${test_suite}" \
71+
--provider "${TEST_PROVIDER}" \
72+
-o /tmp/artifacts/e2e.log \
73+
--junit-dir /tmp/artifacts/junit
74+
else
75+
test_suite=all
76+
if [[ -e "${SHARED_DIR}/test-suite.txt" ]]; then
77+
test_suite=$(<"${SHARED_DIR}/test-suite.txt")
78+
fi
79+
openshift-tests run-upgrade "${test_suite}" \
80+
--to-image "${IMAGE:-${RELEASE_IMAGE_LATEST}}" \
81+
--provider "${TEST_PROVIDER:-}" \
7282
-o /tmp/artifacts/e2e.log \
7383
--junit-dir /tmp/artifacts/junit
84+
fi

ci-operator/step-registry/openshift/e2e/test/openshift-e2e-test-ref.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,8 @@ ref:
88
memory: 600Mi
99
limits:
1010
memory: 4Gi
11+
env:
12+
- name: OPENSHIFT_UPGRADE
13+
default: "false"
1114
documentation: |-
1215
The Openshift E2E step executes the common end-to-end test suite.

0 commit comments

Comments
 (0)