Skip to content
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

Trust check #1469

Merged
merged 5 commits into from Jun 15, 2023
Merged

Trust check #1469

merged 5 commits into from Jun 15, 2023

Conversation

deads2k
Copy link
Contributor

@deads2k deads2k commented Jun 15, 2023

fixed version of #1461

When done after rotating signers, but before rotating targets, it produces

[deads@fedora ~]$ oc adm ocp-certificates remove-old-trust -n openshift-config-managed configmaps --all --dry-run --created-before=2023-06-15T14:04:28-04:00
error: failed to apply changes to openshift-config-managed/kube-apiserver-aggregator-client-ca: secrets only trusted by the old bundle: [secrets/aggregator-client[openshift-kube-apiserver]]
[deads@fedora ~]$ oc adm ocp-certificates remove-old-trust -n openshift-kube-apiserver-operator configmaps --all --dry-run --created-before=2023-06-15T14:04:28-04:00
failed to apply changes to openshift-kube-apiserver-operator/kube-apiserver-to-kubelet-client-ca: secrets only trusted by the old bundle: [secrets/kubelet-client[openshift-kube-apiserver]]
failed to apply changes to openshift-kube-apiserver-operator/kube-control-plane-signer-ca: secrets only trusted by the old bundle: [secrets/kube-scheduler-client-cert-key[openshift-kube-scheduler] secrets/kube-controller-manager-client-cert-key[openshift-config-managed] secrets/kube-scheduler-client-cert-key[openshift-config-managed] secrets/check-endpoints-client-cert-key[openshift-kube-apiserver] secrets/control-plane-node-admin-client-cert-key[openshift-kube-apiserver] secrets/kube-controller-manager-client-cert-key[openshift-kube-controller-manager]]
failed to apply changes to openshift-kube-apiserver-operator/loadbalancer-serving-ca: secrets only trusted by the old bundle: [secrets/external-loadbalancer-serving-certkey[openshift-kube-apiserver] secrets/internal-loadbalancer-serving-certkey[openshift-kube-apiserver]]
failed to apply changes to openshift-kube-apiserver-operator/localhost-recovery-serving-ca: secrets only trusted by the old bundle: [secrets/localhost-recovery-serving-certkey[openshift-kube-apiserver]]
failed to apply changes to openshift-kube-apiserver-operator/localhost-serving-ca: secrets only trusted by the old bundle: [secrets/localhost-serving-cert-certkey[openshift-kube-apiserver]]
failed to apply changes to openshift-kube-apiserver-operator/node-system-admin-ca: secrets only trusted by the old bundle: [secrets/node-system-admin-client[openshift-kube-apiserver-operator]]
failed to apply changes to openshift-kube-apiserver-operator/service-network-serving-ca: secrets only trusted by the old bundle: [secrets/service-network-serving-certkey[openshift-kube-apiserver]]

@openshift-ci openshift-ci bot requested review from ardaguclu and mfojtik June 15, 2023 18:05
@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 15, 2023
@stlaz
Copy link
Member

stlaz commented Jun 15, 2023

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jun 15, 2023
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 15, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: deads2k, stlaz

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

The pull request process is described 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

@deads2k deads2k merged commit 4b81ff4 into openshift:master Jun 15, 2023
6 of 12 checks passed

// TODO need to wire context through the visitorFns
err := visitor.Visit(r.purgeTrustFromResourceInfo)
secretList, err := r.KubeClient.CoreV1().Secrets(metav1.NamespaceAll).List(ctx, metav1.ListOptions{LabelSelector: "auth.openshift.io/managed-certificate-type=target"})
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor nit, this could use the ManagedCertificateTypeLabelName constant

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants