Skip to content

Commit 3b87d5e

Browse files
committed
add the workaround for 4.14.to 4.16
1 parent 18e82d8 commit 3b87d5e

File tree

4 files changed

+122
-8
lines changed

4 files changed

+122
-8
lines changed

ci-operator/config/openshift/openshift-tests-private/openshift-openshift-tests-private-release-4.16__amd64-nightly-4.16-cpou-upgrade-from-4.14.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,16 @@ tests:
8686
- ref: cucushift-upgrade-setedge-2hops
8787
- chain: openshift-upgrade-qe-test-cpou
8888
workflow: cucushift-installer-rehearse-vsphere-upi-encrypt
89+
- as: azure-ipi-workers-rhel8-f28
90+
cron: 21 8 24 * *
91+
steps:
92+
cluster_profile: azure-qe
93+
env:
94+
BASE_DOMAIN: qe.azure.devcluster.openshift.com
95+
test:
96+
- ref: cucushift-upgrade-setedge-2hops
97+
- chain: openshift-upgrade-qe-sanity-cpou
98+
workflow: cucushift-installer-rehearse-azure-ipi-workers-rhel8
8999
zz_generated_metadata:
90100
branch: release-4.16
91101
org: openshift

ci-operator/jobs/openshift/openshift-tests-private/openshift-openshift-tests-private-release-4.16-periodics.yaml

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,85 @@
11
periodics:
2+
- agent: kubernetes
3+
cluster: build09
4+
cron: 21 8 24 * *
5+
decorate: true
6+
decoration_config:
7+
skip_cloning: true
8+
extra_refs:
9+
- base_ref: release-4.16
10+
org: openshift
11+
repo: openshift-tests-private
12+
labels:
13+
ci-operator.openshift.io/cloud: azure4
14+
ci-operator.openshift.io/cloud-cluster-profile: azure-qe
15+
ci-operator.openshift.io/variant: amd64-nightly-4.16-cpou-upgrade-from-4.14
16+
ci.openshift.io/generator: prowgen
17+
pj-rehearse.openshift.io/can-be-rehearsed: "true"
18+
name: periodic-ci-openshift-openshift-tests-private-release-4.16-amd64-nightly-4.16-cpou-upgrade-from-4.14-azure-ipi-workers-rhel8-f28
19+
spec:
20+
containers:
21+
- args:
22+
- --gcs-upload-secret=/secrets/gcs/service-account.json
23+
- --image-import-pull-secret=/etc/pull-secret/.dockerconfigjson
24+
- --lease-server-credentials-file=/etc/boskos/credentials
25+
- --oauth-token-path=/usr/local/github-credentials/oauth
26+
- --report-credentials-file=/etc/report/credentials
27+
- --secret-dir=/secrets/ci-pull-credentials
28+
- --target=azure-ipi-workers-rhel8-f28
29+
- --variant=amd64-nightly-4.16-cpou-upgrade-from-4.14
30+
command:
31+
- ci-operator
32+
image: ci-operator:latest
33+
imagePullPolicy: Always
34+
name: ""
35+
resources:
36+
requests:
37+
cpu: 10m
38+
volumeMounts:
39+
- mountPath: /etc/boskos
40+
name: boskos
41+
readOnly: true
42+
- mountPath: /secrets/ci-pull-credentials
43+
name: ci-pull-credentials
44+
readOnly: true
45+
- mountPath: /secrets/gcs
46+
name: gcs-credentials
47+
readOnly: true
48+
- mountPath: /usr/local/github-credentials
49+
name: github-credentials-openshift-ci-robot-private-git-cloner
50+
readOnly: true
51+
- mountPath: /secrets/manifest-tool
52+
name: manifest-tool-local-pusher
53+
readOnly: true
54+
- mountPath: /etc/pull-secret
55+
name: pull-secret
56+
readOnly: true
57+
- mountPath: /etc/report
58+
name: result-aggregator
59+
readOnly: true
60+
serviceAccountName: ci-operator
61+
volumes:
62+
- name: boskos
63+
secret:
64+
items:
65+
- key: credentials
66+
path: credentials
67+
secretName: boskos-credentials
68+
- name: ci-pull-credentials
69+
secret:
70+
secretName: ci-pull-credentials
71+
- name: github-credentials-openshift-ci-robot-private-git-cloner
72+
secret:
73+
secretName: github-credentials-openshift-ci-robot-private-git-cloner
74+
- name: manifest-tool-local-pusher
75+
secret:
76+
secretName: manifest-tool-local-pusher
77+
- name: pull-secret
78+
secret:
79+
secretName: registry-pull-credentials
80+
- name: result-aggregator
81+
secret:
82+
secretName: result-aggregator
283
- agent: kubernetes
384
cluster: build09
485
cron: 58 14 25 * *

ci-operator/step-registry/cucushift/chainupgrade/toimage/cucushift-chainupgrade-toimage-commands.sh

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,30 @@ EOF
308308
ansible-playbook -i "${SHARED_DIR}/ansible-hosts" /tmp/repo.yaml -vvv
309309
}
310310

311+
function rhel_pre_unpause(){
312+
echo "Running the workaround step before unpausing worker mcp"
313+
local testcase="rhel"
314+
cat > /tmp/rhel_pre_unpause.yaml <<-'EOF'
315+
---
316+
- name: RHEL pre-unpause playbook
317+
hosts: workers
318+
any_errors_fatal: true
319+
gather_facts: false
320+
vars:
321+
required_packages:
322+
- ose-azure-acr-image-credential-provider
323+
- ose-gcp-gcr-image-credential-provider
324+
tasks:
325+
- name: Install required package on the node
326+
dnf:
327+
name: "{{ required_packages }}"
328+
state: latest
329+
disable_gpg_check: true
330+
EOF
331+
ansible-inventory -i "${SHARED_DIR}/ansible-hosts" --list --yaml
332+
ansible-playbook -i "${SHARED_DIR}/ansible-hosts" /tmp/rhel_pre_unpause.yaml -vvv
333+
}
334+
311335
# Do sdn migration to ovn since sdn is not supported from 4.17 version
312336
function sdn2ovn(){
313337
oc patch network.operator.openshift.io cluster --type='merge' -p='{"spec":{"defaultNetwork":{"ovnKubernetesConfig":{"ipv4":{"internalJoinSubnet": "100.65.0.0/16"}}}}}'
@@ -1152,6 +1176,11 @@ for target in "${TARGET_RELEASES[@]}"; do
11521176
run_command "oc get node -owide"
11531177
if [[ $(oc get machineconfigpools worker -ojson | jq -r '.spec.paused') == "true" ]]; then
11541178
echo "worker mcp are paused, it sounds eus upgrade, skip rhel worker upgrade here, should upgrade them after worker mcp unpaused"
1179+
if [[ "${SOURCE_MINOR_VERSION}" == "14" ]]; then
1180+
echo "Workaround for https://issues.redhat.com/browse/OCPBUGS-32057 in 4.14 to 4.16 cpou test"
1181+
rhel_repo
1182+
rhel_pre_unpause
1183+
fi
11551184
else
11561185
rhel_repo
11571186
rhel_upgrade

ci-operator/step-registry/cucushift/upgrade/cpou/unpause-worker-mcp/cucushift-upgrade-cpou-unpause-worker-mcp-commands.sh

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -100,11 +100,5 @@ do
100100
printf "\n"
101101
unpause ${mcp}
102102
printf "\n"
103-
if [[ "${current_minor_ver}" -lt "19" ]] && [[ $(oc get nodes -l node.openshift.io/os_id=rhel) != "" ]]; then
104-
echo "Found rhel worker, this step is supposed to be used in eus upgrade, skipping mcp checking here, need to check it after rhel worker upgraded..."
105-
run_command "oc get machineconfigpools"
106-
run_command "oc get node -owide"
107-
else
108-
check_mcp ${mcp} "True"
109-
fi
110-
done
103+
check_mcp ${mcp} "True"
104+
done

0 commit comments

Comments
 (0)