Skip to content

MCO-1282: Remove all code related to the Image Registry workaround Config Map #5093

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

CourtCourt521
Copy link
Contributor

@CourtCourt521 CourtCourt521 commented May 29, 2025

- What I did

Removed all code and related alerts for the Image Registry Workaround due to NodeDisruptionPolicy going GA.

- How to verify it

// Apply imagecontentsourcepolicy

apiVersion: operator.openshift.io/v1alpha1
kind: ImageContentSourcePolicy
metadata:
  name: quay-mirror
spec:
  repositoryDigestMirrors:
  - mirrors:
    - my-quay.io.mirror
    source: quay.io
    
cruhm@cruhm-thinkpadp16vgen1:~$ vim imagecontent.yaml
cruhm@cruhm-thinkpadp16vgen1:~$ oc create -f imagecontent.yaml 
imagecontentsourcepolicy.operator.openshift.io/quay-mirror created

// Apply override config map

apiVersion: v1
kind: ConfigMap
metadata:
  name: image-registry-override-drain
  namespace: openshift-machine-config-operator
  
cruhm@cruhm-thinkpadp16vgen1:~$ vim override.yaml
cruhm@cruhm-thinkpadp16vgen1:~$ oc apply -f override.yaml 
configmap/image-registry-override-drain created

// Wait for the initial MCP rollover to finish. Check to make sure that the MCODrainOverrideConfigMapAlert exists and no longer fires

cruhm@cruhm-thinkpadp16vgen1:~/frr/jshivers/frr$ oc get configmap prometheus-k8s-rulefiles-0 -o yaml | grep MCODrainOverrideConfigMapAlert

cruhm@cruhm-thinkpadp16vgen1:~/frr/jshivers/frr$

// Delete the ImageContentSourcePolicy. You should see the MCP rollover again even with the override file present.

cruhm@cruhm-thinkpadp16vgen1:~$ oc get mcp
NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   True      False      False      3              3                   3                     0                      65m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   True      False      False      3              3                   3                     0                      65m

$ oc delete ImageContentSourcePolicy quay-mirror

cruhm@cruhm-thinkpadp16vgen1:~$ oc get mcp 
NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   False     True       False      3              0                   0                     0                      66m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   False     True       False      3              0                   0                     0                      66m

- Description for the changelog

Remove all code related to the Image Registry workaround Config Map

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label May 29, 2025
@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented May 29, 2025

@CourtCourt521: This pull request references MCO-1282 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.20.0" version, but no target version was set.

In response to this:

- What I did

Removed all code and related alerts for the Image Registry Workaround due to NodeDisruptionPolicy going GA.

- How to verify it

WIP

- Description for the changelog

Remove all code related to the Image Registry workaround Config Map

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 29, 2025
Copy link
Contributor

openshift-ci bot commented May 29, 2025

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

Copy link
Contributor

openshift-ci bot commented May 29, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: CourtCourt521
Once this PR has been reviewed and has the lgtm label, please assign cheesesashimi for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@CourtCourt521
Copy link
Contributor Author

TESTING

// Before applying imagecontent and workaround

cruhm@cruhm-thinkpadp16vgen1:~/frr/jshivers/frr$ oc get mcp
NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-1cd832161bba7432ba209f4f88f2ccb2   True      False      False      3              3                   3                     0                      61m
worker   rendered-worker-0d2fc42c24be368229abfd9b1d42f132   True      False      False      3              3                   3                     0                      61m

// Apply imagecontentsourcepolicy

apiVersion: operator.openshift.io/v1alpha1
kind: ImageContentSourcePolicy
metadata:
  name: quay-mirror
spec:
  repositoryDigestMirrors:
  - mirrors:
    - my-quay.io.mirror
    source: quay.io
    
cruhm@cruhm-thinkpadp16vgen1:~$ vim imagecontent.yaml
cruhm@cruhm-thinkpadp16vgen1:~$ oc create -f imagecontent.yaml 
imagecontentsourcepolicy.operator.openshift.io/quay-mirror created

// Apply override config map

apiVersion: v1
kind: ConfigMap
metadata:
  name: image-registry-override-drain
  namespace: openshift-machine-config-operator
  
cruhm@cruhm-thinkpadp16vgen1:~$ vim override.yaml
cruhm@cruhm-thinkpadp16vgen1:~$ oc apply -f override.yaml 
configmap/image-registry-override-drain created

// Remove imagecontentsource policy and we should still see it reboot

cruhm@cruhm-thinkpadp16vgen1:~$ oc get mcp
NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   True      False      False      3              3                   3                     0                      65m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   True      False      False      3              3                   3                     0                      65m

$ oc delete ImageContentSourcePolicy quay-mirror

cruhm@cruhm-thinkpadp16vgen1:~$ oc get mcp 
NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   False     True       False      3              0                   0                     0                      66m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   False     True       False      3              0                   0                     0                      66m


NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   False     True	 False      3              0                   0                     0                      68m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   False     True	 False      3              1                   1                     0                      68m

NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   False     True	 False      3              1                   1                     0                      70m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   False     True	 False      3              2                   2                     0                      70m

NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-1cd832161bba7432ba209f4f88f2ccb2   True      False	 False      3              3                   3                     0                      75m
worker   rendered-worker-0d2fc42c24be368229abfd9b1d42f132   True      False	 False      3              3                   3                     0                      75m

// See that the override configmap is still present

cruhm@cruhm-thinkpadp16vgen1:~$ oc get configmap -n openshift-machine-config-operator
NAME                             DATA   AGE
coreos-bootimages                4      80m
image-registry-override-drain    0      12m
kube-rbac-proxy                  1      80m
kube-root-ca.crt                 1      80m
kubeconfig-data                  1      71m
machine-config-operator-images   1      80m
machine-config-osimageurl        4      80m
machine-config-server-ca         1      80m
openshift-service-ca.crt         1      80m

@CourtCourt521
Copy link
Contributor Author

CourtCourt521 commented Jun 3, 2025

// MCODrainOverrideConfigMapAlert alert is removed and can no longer fire.

cruhm@cruhm-thinkpadp16vgen1:~/frr/jshivers/frr$ oc get configmap prometheus-k8s-rulefiles-0 -o yaml | grep MCODrainOverrideConfigMapAlert

cruhm@cruhm-thinkpadp16vgen1:~/frr/jshivers/frr$

@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jun 3, 2025

@CourtCourt521: This pull request references MCO-1282 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.20.0" version, but no target version was set.

In response to this:

- What I did

Removed all code and related alerts for the Image Registry Workaround due to NodeDisruptionPolicy going GA.

- How to verify it

// Apply imagecontentsourcepolicy

apiVersion: operator.openshift.io/v1alpha1
kind: ImageContentSourcePolicy
metadata:
 name: quay-mirror
spec:
 repositoryDigestMirrors:
 - mirrors:
   - my-quay.io.mirror
   source: quay.io
   
cruhm@cruhm-thinkpadp16vgen1:~$ vim imagecontent.yaml
cruhm@cruhm-thinkpadp16vgen1:~$ oc create -f imagecontent.yaml 
imagecontentsourcepolicy.operator.openshift.io/quay-mirror created

// Apply override config map

apiVersion: v1
kind: ConfigMap
metadata:
 name: image-registry-override-drain
 namespace: openshift-machine-config-operator
 
cruhm@cruhm-thinkpadp16vgen1:~$ vim override.yaml
cruhm@cruhm-thinkpadp16vgen1:~$ oc apply -f override.yaml 
configmap/image-registry-override-drain created

// Wait for the initial MCP rollover to finish. Check to make sure that the MCODrainOverrideConfigMapAlert exists and no longer fires

cruhm@cruhm-thinkpadp16vgen1:~/frr/jshivers/frr$ oc get configmap prometheus-k8s-rulefiles-0 -o yaml | grep MCODrainOverrideConfigMapAlert

cruhm@cruhm-thinkpadp16vgen1:~/frr/jshivers/frr$

// Delete the ImageContentSourcePolicy. You should see the MCP rollover again even with the override file present.

cruhm@cruhm-thinkpadp16vgen1:~$ oc get mcp
NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   True      False      False      3              3                   3                     0                      65m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   True      False      False      3              3                   3                     0                      65m

$ oc delete ImageContentSourcePolicy quay-mirror

cruhm@cruhm-thinkpadp16vgen1:~$ oc get mcp 
NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   False     True       False      3              0                   0                     0                      66m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   False     True       False      3              0                   0                     0                      66m

- Description for the changelog

Remove all code related to the Image Registry workaround Config Map

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Jun 3, 2025

@CourtCourt521: This pull request references MCO-1282 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.20.0" version, but no target version was set.

In response to this:

- What I did

Removed all code and related alerts for the Image Registry Workaround due to NodeDisruptionPolicy going GA.

- How to verify it

// Apply imagecontentsourcepolicy

apiVersion: operator.openshift.io/v1alpha1
kind: ImageContentSourcePolicy
metadata:
 name: quay-mirror
spec:
 repositoryDigestMirrors:
 - mirrors:
   - my-quay.io.mirror
   source: quay.io
   
cruhm@cruhm-thinkpadp16vgen1:~$ vim imagecontent.yaml
cruhm@cruhm-thinkpadp16vgen1:~$ oc create -f imagecontent.yaml 
imagecontentsourcepolicy.operator.openshift.io/quay-mirror created

// Apply override config map

apiVersion: v1
kind: ConfigMap
metadata:
 name: image-registry-override-drain
 namespace: openshift-machine-config-operator
 
cruhm@cruhm-thinkpadp16vgen1:~$ vim override.yaml
cruhm@cruhm-thinkpadp16vgen1:~$ oc apply -f override.yaml 
configmap/image-registry-override-drain created

// Wait for the initial MCP rollover to finish. Check to make sure that the MCODrainOverrideConfigMapAlert exists and no longer fires

cruhm@cruhm-thinkpadp16vgen1:~/frr/jshivers/frr$ oc get configmap prometheus-k8s-rulefiles-0 -o yaml | grep MCODrainOverrideConfigMapAlert

cruhm@cruhm-thinkpadp16vgen1:~/frr/jshivers/frr$

// Delete the ImageContentSourcePolicy. You should see the MCP rollover again even with the override file present.

cruhm@cruhm-thinkpadp16vgen1:~$ oc get mcp
NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   True      False      False      3              3                   3                     0                      65m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   True      False      False      3              3                   3                     0                      65m

$ oc delete ImageContentSourcePolicy quay-mirror

cruhm@cruhm-thinkpadp16vgen1:~$ oc get mcp 
NAME     CONFIG                                             UPDATED   UPDATING   DEGRADED   MACHINECOUNT   READYMACHINECOUNT   UPDATEDMACHINECOUNT   DEGRADEDMACHINECOUNT   AGE
master   rendered-master-aa75b71b868b370bb85e66fe0d82d293   False     True       False      3              0                   0                     0                      66m
worker   rendered-worker-d9cd5ae52d8e497b19fc8f39532486ff   False     True       False      3              0                   0                     0                      66m

- Description for the changelog

Remove all code related to the Image Registry workaround Config Map

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@CourtCourt521 CourtCourt521 marked this pull request as ready for review June 3, 2025 22:02
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jun 3, 2025
Copy link
Contributor

openshift-ci bot commented Jun 4, 2025

@CourtCourt521: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-gcp-op-ocl 0d80248 link false /test e2e-gcp-op-ocl
ci/prow/okd-scos-e2e-aws-ovn 0d80248 link false /test okd-scos-e2e-aws-ovn
ci/prow/e2e-azure-ovn-upgrade-out-of-change 0d80248 link false /test e2e-azure-ovn-upgrade-out-of-change

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants