[cifmw_helpers] Fix CRC certificate renewal wait using kubeconfig#3989
Conversation
|
Skipping CI for Draft Pull Request. |
that's not true :) The generated kubeconfig contains few ids, no password needed due not via password authorization is done :) Probably with new Zuul CI, new Ansible module are installed so it can not find kubeconfig in proper localization. |
That's the error, that i found. If you have any suggestions, please feel free to share them. |
The oc login command in crc_start.yml was missing the -p (password) flag, causing every retry to fail with 401 Unauthorized regardless of cluster health. This code path was never exercised until ~2026-06-03 when the CRC image certificates expired, breaking all CRC-based molecule jobs. Replace oc login with oc get nodes using the CRC kubeconfig file. This avoids the OAuth dependency during certificate renewal and does not require credentials. Also increase retries from 90 to 150 (~25 minutes) to cover the observed recovery time. Signed-off-by: Vito Castellano <vcastell@redhat.com>
6b5d3ae to
40bee61
Compare
|
/lgtm |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: nemarjan The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
nemarjan
left a comment
There was a problem hiding this comment.
/lgtm
I tested my MR with this change and it has fixed the issue: https://gateway-cloud-softwarefactory.apps.ocp.cloud.ci.centos.org/zuul/t/rdoproject.org/build/5c08905906cd453fb7613d8d7ccaf153
592d089
into
openstack-k8s-operators:main
Problem
Since ~2026-06-03, all CRC-based molecule jobs (
ci_local_storage,env_op_images, etc.) fail consistently during the prepare phase, stuck onTASK [cifmw_helpers : Login to the OpenShift when certificate is expired]for 15 minutes before timing out with 401 Unauthorized.Root cause
The
oc login -u kubeadmincommand incrc_start.ymlnever included the p flag. In non-interactive CI the empty password always returns 401, regardless of cluster state.Fix
oc loginwithoc get nodes --kubeconfig=...which uses the CRC kubeconfig file directly, avoiding the OAuth dependency and the need for credentials during certificate renewal.Refs: