-
Notifications
You must be signed in to change notification settings - Fork 194
OTA-917: pkg/customsignaturestore: Implement signatureStores customization #994
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
OTA-917: pkg/customsignaturestore: Implement signatureStores customization #994
Conversation
@wking: This pull request references OTA-917 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.15.0" version, but no target version was set. In response to this:
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/test-infra repository. |
@wking: No Jira issue is referenced in the title of this pull request. In response to this:
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/test-infra repository. |
@wking: This pull request references OTA-917 which is a valid jira issue. In response to this:
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/test-infra repository. |
0c1888b
to
1666d12
Compare
/cc |
1666d12
to
6480fe9
Compare
ClusterBot testing looks good with $ oc patch clusterversion version --type json -p '[{"op": "add", "path": "/spec/upstream", "value": "https://raw.githubusercontent.com/wking/cincinnati-graph-data/signatureStores-demo/cincinnati-graph.json"}]'
$ oc adm upgrade channel demo
$ oc adm upgrade --to 4.15.1
$ oc adm upgrade
Cluster version is 4.15.0-0.test-2023-11-17-182139-ci-ln-wbgj66k-latest
ReleaseAccepted=False
Reason: VerifyPayloadVersion
Message: Verifying payload failed version="4.15.1" image="quay.io/openshift-release-dev/ocp-release@sha256:beda83fb057e328d6f94f8415382350ca3ddf99bb9094e262184e0f127810ce0" failure=release image version 4.13.0 does not match the expected upstream version 4.15.1
Upstream: https://raw.githubusercontent.com/wking/cincinnati-graph-data/signatureStores-demo/cincinnati-graph.json
Channel: demo
Recommended updates:
VERSION IMAGE
4.15.1 quay.io/openshift-release-dev/ocp-release@sha256:beda83fb057e328d6f94f8415382350ca3ddf99bb9094e262184e0f127810ce0 That isn't initiating the update, because the 4.13.0 signature I stuck in my dummy branch's signature store doesn't match the 4.15.1 version name I stuck in my dummy-branch's graph. But it is getting past the "is there a signature that I trust" stage. And shifting the signature in my dummy branch out of the correct spot, I was getting:
which is my custom store config successfully blocking access to the default stores, which contain a signature for that digest. |
6480fe9
to
eafafd9
Compare
e86ae23
to
f85f95a
Compare
/payload-job periodic-ci-openshift-release-master-ci-4.15-e2e-aws-sdn-techpreview |
@wking: trigger 1 job(s) for the /payload-(job|aggregate) command
See details on https://pr-payload-tests.ci.openshift.org/runs/ci/00fba6e0-92cc-11ee-87ea-f0be85fbf320-0 |
/retest-required |
a9f10b6
to
02957bb
Compare
/hold cancel |
…grade manifests Avoid (from before CustomNoUpgrade was added to Pratik's then-in-flight API pull request): $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/origin-ci-test/logs/openshift-cluster-version-operator-994-ci-4.15-e2e-aws-sdn-techpreview/1731729833685159936/artifacts/e2e-aws-sdn-techpreview/ipi-install-install/artifacts/log-bundle-20231204181454.tar | tar tvz | grep clusterversion -rw-r--r-- core/core 37761 2023-12-04 10:14 log-bundle-20231204181454/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversion-TechPreviewNoUpgrade.crd.yaml -rw-r--r-- core/core 35109 2023-12-04 10:14 log-bundle-20231204181454/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversion-Default.crd.yaml -rw-r--r-- core/core 37761 2023-12-04 10:14 log-bundle-20231204181454/rendered-assets/openshift/manifests/0000_00_cluster-version-operator_01_clusterversion-TechPreviewNoUpgrade.crd.yaml -rw-r--r-- core/core 35109 2023-12-04 10:14 log-bundle-20231204181454/rendered-assets/openshift/manifests/0000_00_cluster-version-operator_01_clusterversion-Default.crd.yaml doubling up on the CRD, now that there are Default, CustomNoUpgrade, and TechPreviewNoUpgrade flavors. We'll need something more robust than my current approach if a future tech-preview-only manifest is necessary at bootstrap-rendering, but we can figure that out if we ever get that kind of feature in the CVO.
Address [1]: pkg/cincinnati/cincinnati.go:119:4: printf: (k8s.io/klog/v2.Verbose).Infof format %n has unknown verb n (govet) klog.V(2).Infof("Using a root CA pool with %n root CA subjects to request updates from %s", len(c.transport.TLSClientConfig.RootCAs.Subjects()), uri) ^ pkg/payload/precondition/clusterversion/upgradeable.go:91:3: printf: (k8s.io/klog/v2.Verbose).Infof call needs 3 args but has 4 args (govet) klog.V(2).Infof("Precondition %q passed: minor from the target %s is not a minor version update from the current %s.", pf.Name(), releaseContext.DesiredVersion, currentVersion, currentMinor) ^ The %n is from that log line originally getting added in 116b2c5 (pkg/cincinnati: Log the proxy/TLS settings used for upstream fetches, 2021-05-18, openshift#568). The accidentally unrendere currentMinor is from e17c964 (pkg/payload/precondition/clusterversion/upgradeable: Only block on minor-version updates, 2023-09-14, openshift#968). [1]: https://prow.ci.openshift.org/view/gs/origin-ci-test/pr-logs/pull/openshift_cluster-version-operator/994/pull-ci-openshift-cluster-version-operator-master-lint/1732497738395815936#1:build-log.txt%3A20-25
02957bb
to
c798c3c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: LalatenduMohanty, petr-muller, wking 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 |
/retest-required |
/retest-required |
/test e2e-agnostic-ovn |
/test e2e-hypershift |
so close to branch-cut, I'm adding |
Disruption errors and HyperShift CI account OIDC quotas are both unrelated, because there isn't any CI logic yet to excercise signature retrieval (because we don't sign CI release builds). /override ci/prow/e2e-agnostic-ovn |
@wking: Overrode contexts on behalf of wking: ci/prow/e2e-agnostic-ovn, ci/prow/e2e-hypershift In response to this:
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/test-infra repository. |
@wking: all tests passed! 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/test-infra repository. I understand the commands that are listed here. |
[ART PR BUILD NOTIFIER] This PR has been included in build cluster-version-operator-container-v4.15.0-202312080808.p0.gebe0f34.assembly.stream for distgit cluster-version-operator. |
Catching up with the YAML getting shifted into a subdirectory [1]. I followed the new docs from [2] to create pkg/dependencymagnet, and then: $ emacs pkg/featuregates/featuregates.go # configv1.FeatureGateUpgradeStatus -> features.FeatureGateUpgradeStatus $ go get github.com/openshift/api@master github.com/openshift/library-go@master $ go mod tidy $ go mod vendor $ sed -i 's|config/v1/0000_00_cluster-version-operator|config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator|g' $(git grep -l 0000_00_cluster-version-operator) $ git add -A Dockerfile* hack/test-prerequisites.go pkg/dependencymagnet go.* vendor all using: $ go version go version go1.22.2 linux/amd64 A few points on the invocation: * I usually use 'go get -u ...', e.g. a98232f (vendor: Bump openshift/api to pick up signatureStores, 2023-12-04, openshift#994), but in this case, that would pull in k8s.io/[email protected], and we want to stick with 0.29 until our release-4.16 branch stops following this development branch. * I'm explicitly bumping library-go, because if I don't, builds on [3]: Building github.com/openshift/cluster-version-operator (v1.0.0-1203-g258de3f7-dirty) # github.com/openshift/library-go/pkg/manifest vendor/github.com/openshift/library-go/pkg/manifest/manifest.go:32:35: undefined: configv1.FeatureSets # github.com/openshift/cluster-version-operator/pkg/featuregates pkg/featuregates/featuregates.go:92:32: undefined: configv1.FeatureGateUpgradeStatus pkg/featuregates/featuregates.go:97:33: undefined: configv1.FeatureGateUpgradeStatus If I had been able to use -u, library-go would have automatically floated to the tip commit anyway. But either way, I still needed to make manual changes to keep up with [4] moving to the new openshift/api/features package. [1]: openshift/api#1814 [2]: openshift/api@06baaa4#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5R211 [3]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-images/1785396933666279424#1:build-log.txt%3A74-79 [4]: openshift/api#1821
Catching up with the YAML getting shifted into a subdirectory [1]. I followed the new docs from [2] to create pkg/dependencymagnet, and then: $ emacs pkg/featuregates/featuregates.go pkg/featuregates/featurechangestopper_test.go # configv1.FeatureGateUpgradeStatus -> features.FeatureGateUpgradeStatus $ go get github.com/openshift/api@master github.com/openshift/library-go@master $ go mod tidy $ go mod vendor $ sed -i 's|config/v1/0000_00_cluster-version-operator|config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator|g' $(git grep -l 0000_00_cluster-version-operator) $ git add -A Dockerfile* hack/test-prerequisites.go pkg/dependencymagnet go.* vendor all using: $ go version go version go1.22.2 linux/amd64 A few points on the invocation: * I usually use 'go get -u ...', e.g. a98232f (vendor: Bump openshift/api to pick up signatureStores, 2023-12-04, openshift#994), but in this case, that would pull in k8s.io/[email protected], and we want to stick with 0.29 until our release-4.16 branch stops following this development branch. * I'm explicitly bumping library-go, because if I don't, builds on [3]: Building github.com/openshift/cluster-version-operator (v1.0.0-1203-g258de3f7-dirty) # github.com/openshift/library-go/pkg/manifest vendor/github.com/openshift/library-go/pkg/manifest/manifest.go:32:35: undefined: configv1.FeatureSets # github.com/openshift/cluster-version-operator/pkg/featuregates pkg/featuregates/featuregates.go:92:32: undefined: configv1.FeatureGateUpgradeStatus pkg/featuregates/featuregates.go:97:33: undefined: configv1.FeatureGateUpgradeStatus If I had been able to use -u, library-go would have automatically floated to the tip commit anyway. But either way, I still needed to make manual changes to keep up with [4] moving to the new openshift/api/features package. [1]: openshift/api#1814 [2]: openshift/api@06baaa4#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5R211 [3]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-images/1785396933666279424#1:build-log.txt%3A74-79 [4]: openshift/api#1821
Catching up with the YAML getting shifted into a subdirectory [1]. I followed the new docs from [2] to create pkg/dependencymagnet, and then: $ emacs pkg/featuregates/featuregates.go pkg/featuregates/featurechangestopper_test.go # configv1.FeatureGateUpgradeStatus -> features.FeatureGateUpgradeStatus $ go get github.com/openshift/api@master github.com/openshift/library-go@master $ go mod tidy $ go mod vendor $ sed -i 's|config/v1/0000_00_cluster-version-operator|config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator|g' $(git grep -l 0000_00_cluster-version-operator) $ git add -A Dockerfile* hack/test-prerequisites.go pkg/dependencymagnet go.* vendor all using: $ go version go version go1.22.2 linux/amd64 A few points on the invocation: * I usually use 'go get -u ...', e.g. a98232f (vendor: Bump openshift/api to pick up signatureStores, 2023-12-04, openshift#994), but in this case, that would pull in k8s.io/[email protected], and we want to stick with 0.29 until our release-4.16 branch stops following this development branch. * I'm explicitly bumping library-go, because if I don't, builds fail on [3]: Building github.com/openshift/cluster-version-operator (v1.0.0-1203-g258de3f7-dirty) # github.com/openshift/library-go/pkg/manifest vendor/github.com/openshift/library-go/pkg/manifest/manifest.go:32:35: undefined: configv1.FeatureSets # github.com/openshift/cluster-version-operator/pkg/featuregates pkg/featuregates/featuregates.go:92:32: undefined: configv1.FeatureGateUpgradeStatus pkg/featuregates/featuregates.go:97:33: undefined: configv1.FeatureGateUpgradeStatus If I had been able to use -u, library-go would have automatically floated to the tip commit anyway. But either way, I still needed to make manual changes to keep up with [4] moving to the new openshift/api/features package. [1]: openshift/api#1814 [2]: openshift/api@06baaa4#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5R211 [3]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-images/1785396933666279424#1:build-log.txt%3A74-79 [4]: openshift/api#1821
Catching up with the YAML getting shifted into a subdirectory [1]. I followed the new docs from [2] to create pkg/dependencymagnet, and then: $ emacs pkg/featuregates/featuregates.go pkg/featuregates/featurechangestopper_test.go # configv1.FeatureGateUpgradeStatus -> features.FeatureGateUpgradeStatus $ go get github.com/openshift/api@master github.com/openshift/library-go@master $ go mod tidy $ go mod vendor $ sed -i 's|config/v1/0000_00_cluster-version-operator|config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator|g' $(git grep -l 0000_00_cluster-version-operator) $ git add -A Dockerfile* hack/test-prerequisites.go pkg/dependencymagnet go.* vendor all using: $ go version go version go1.22.2 linux/amd64 A few points on the invocation: * I usually use 'go get -u ...', e.g. a98232f (vendor: Bump openshift/api to pick up signatureStores, 2023-12-04, openshift#994), but in this case, that would pull in k8s.io/[email protected], and we want to stick with 0.29 until our release-4.16 branch stops following this development branch. * I'm explicitly bumping library-go, because if I don't, builds fail on [3]: Building github.com/openshift/cluster-version-operator (v1.0.0-1203-g258de3f7-dirty) # github.com/openshift/library-go/pkg/manifest vendor/github.com/openshift/library-go/pkg/manifest/manifest.go:32:35: undefined: configv1.FeatureSets # github.com/openshift/cluster-version-operator/pkg/featuregates pkg/featuregates/featuregates.go:92:32: undefined: configv1.FeatureGateUpgradeStatus pkg/featuregates/featuregates.go:97:33: undefined: configv1.FeatureGateUpgradeStatus If I had been able to use -u, library-go would have automatically floated to the tip commit anyway. But either way, I still needed to make manual changes to keep up with [4] moving to the new openshift/api/features package. And I want [5]. [1]: openshift/api#1814 [2]: openshift/api@06baaa4#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5R211 [3]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-images/1785396933666279424#1:build-log.txt%3A74-79 [4]: openshift/api#1821 [5]: openshift/library-go#1759
Catching up with the YAML getting shifted into a subdirectory [1]. I followed the new docs from [2] to create pkg/dependencymagnet, and then: $ emacs pkg/featuregates/featuregates.go pkg/featuregates/featurechangestopper_test.go # configv1.FeatureGateUpgradeStatus -> features.FeatureGateUpgradeStatus $ go get github.com/openshift/api@master github.com/openshift/library-go@master $ go mod tidy $ go mod vendor $ sed -i 's|config/v1/0000_00_cluster-version-operator|config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator|g' $(git grep -l 0000_00_cluster-version-operator) $ git checkout a90cec9 -- pkg/payload/render.go # Eran Cohen's DevPreviewNoUpgrade exclusion $ git add -A Dockerfile* hack/test-prerequisites.go pkg/dependencymagnet go.* vendor all using: $ go version go version go1.22.2 linux/amd64 A few points on the invocation: * I usually use 'go get -u ...', e.g. a98232f (vendor: Bump openshift/api to pick up signatureStores, 2023-12-04, openshift#994), but in this case, that would pull in k8s.io/[email protected], and we want to stick with 0.29 until our release-4.16 branch stops following this development branch. * I'm explicitly bumping library-go, because if I don't, builds fail on [3]: Building github.com/openshift/cluster-version-operator (v1.0.0-1203-g258de3f7-dirty) # github.com/openshift/library-go/pkg/manifest vendor/github.com/openshift/library-go/pkg/manifest/manifest.go:32:35: undefined: configv1.FeatureSets # github.com/openshift/cluster-version-operator/pkg/featuregates pkg/featuregates/featuregates.go:92:32: undefined: configv1.FeatureGateUpgradeStatus pkg/featuregates/featuregates.go:97:33: undefined: configv1.FeatureGateUpgradeStatus If I had been able to use -u, library-go would have automatically floated to the tip commit anyway. But either way, I still needed to make manual changes to keep up with [4] moving to the new openshift/api/features package. And I want [5]. * The DevPreviewNoUpgrade exclusion avoids bootstrap failures like [6]: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808/artifacts/e2e-aws-ovn-techpreview/ipi-install-install/artifacts/log-bundle-20240709194524.tar | tar -xOz log-bundle-20240709194524/bootstrap/journals/bootkube.log | grep 'are not consistent so results would be unpredictable depending on apply order' | tail -n4 Jul 09 19:45:15 ip-10-0-155-191 kube-apiserver-render[74584]: F0709 19:45:15.447834 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:15 ip-10-0-155-191 bootkube.sh[74561]: F0709 19:45:15.447834 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:27 ip-10-0-155-191 kube-apiserver-render[75368]: F0709 19:45:27.669093 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:27 ip-10-0-155-191 bootkube.sh[75345]: F0709 19:45:27.669093 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values as the kube-apiserver-render command worries about the CVO having rendered two ClusterVersion CRDs: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808/artifacts/e2e-aws-ovn-techpreview/ipi-install-install/artifacts/log-bundle-20240709194524.tar | tar -tvz | grep 'cvo-bootstrap/.*cluster-version-operator.*crd' -rw-r--r-- core/core 42129 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml -rw-r--r-- core/core 39010 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml -rw-r--r-- core/core 7628 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusteroperators.crd.yaml [1]: openshift/api#1814 [2]: openshift/api@06baaa4#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5R211 [3]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-images/1785396933666279424#1:build-log.txt%3A74-79 [4]: openshift/api#1821 [5]: openshift/library-go#1759 [6]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808
Catching up with the YAML getting shifted into a subdirectory [1]. I followed the new docs from [2] to create pkg/dependencymagnet, and then: $ emacs pkg/featuregates/featuregates.go pkg/featuregates/featurechangestopper_test.go # configv1.FeatureGateUpgradeStatus -> features.FeatureGateUpgradeStatus $ go get github.com/openshift/api@master github.com/openshift/library-go@master $ go mod tidy $ go mod vendor $ sed -i 's|config/v1/0000_00_cluster-version-operator|config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator|g' $(git grep -l 0000_00_cluster-version-operator) $ sed -i 's/\(clusterversion\|clusteroperator\)/\1s/' hack/test-prerequisites.go $ git checkout a90cec9 -- pkg/payload/render.go # Eran Cohen's DevPreviewNoUpgrade exclusion $ git add -A Dockerfile* hack/test-prerequisites.go pkg/dependencymagnet go.* vendor all using: $ go version go version go1.22.2 linux/amd64 A few points on the invocation: * I usually use 'go get -u ...', e.g. a98232f (vendor: Bump openshift/api to pick up signatureStores, 2023-12-04, openshift#994), but in this case, that would pull in k8s.io/[email protected], and we want to stick with 0.29 until our release-4.16 branch stops following this development branch. * I'm explicitly bumping library-go, because if I don't, builds fail on [3]: Building github.com/openshift/cluster-version-operator (v1.0.0-1203-g258de3f7-dirty) # github.com/openshift/library-go/pkg/manifest vendor/github.com/openshift/library-go/pkg/manifest/manifest.go:32:35: undefined: configv1.FeatureSets # github.com/openshift/cluster-version-operator/pkg/featuregates pkg/featuregates/featuregates.go:92:32: undefined: configv1.FeatureGateUpgradeStatus pkg/featuregates/featuregates.go:97:33: undefined: configv1.FeatureGateUpgradeStatus If I had been able to use -u, library-go would have automatically floated to the tip commit anyway. But either way, I still needed to make manual changes to keep up with [4] moving to the new openshift/api/features package. And I want [5]. * The DevPreviewNoUpgrade exclusion avoids bootstrap failures like [6]: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808/artifacts/e2e-aws-ovn-techpreview/ipi-install-install/artifacts/log-bundle-20240709194524.tar | tar -xOz log-bundle-20240709194524/bootstrap/journals/bootkube.log | grep 'are not consistent so results would be unpredictable depending on apply order' | tail -n4 Jul 09 19:45:15 ip-10-0-155-191 kube-apiserver-render[74584]: F0709 19:45:15.447834 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:15 ip-10-0-155-191 bootkube.sh[74561]: F0709 19:45:15.447834 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:27 ip-10-0-155-191 kube-apiserver-render[75368]: F0709 19:45:27.669093 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:27 ip-10-0-155-191 bootkube.sh[75345]: F0709 19:45:27.669093 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values as the kube-apiserver-render command worries about the CVO having rendered two ClusterVersion CRDs: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808/artifacts/e2e-aws-ovn-techpreview/ipi-install-install/artifacts/log-bundle-20240709194524.tar | tar -tvz | grep 'cvo-bootstrap/.*cluster-version-operator.*crd' -rw-r--r-- core/core 42129 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml -rw-r--r-- core/core 39010 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml -rw-r--r-- core/core 7628 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusteroperators.crd.yaml [1]: openshift/api#1814 [2]: openshift/api@06baaa4#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5R211 [3]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-images/1785396933666279424#1:build-log.txt%3A74-79 [4]: openshift/api#1821 [5]: openshift/library-go#1759 [6]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808
Like e9762c6 (vendor: Update openshift/api to pick up zz_generated.crd-manifests, 2024-04-30, openshift#1045), except I pulled release-4.16 branches. Catching up with the YAML getting shifted into a subdirectory [1]. I followed the new docs from [2] to create pkg/dependencymagnet, and then: $ emacs pkg/featuregates/featuregates.go pkg/featuregates/featurechangestopper_test.go # configv1.FeatureGateUpgradeStatus -> features.FeatureGateUpgradeStatus $ go get github.com/openshift/[email protected] github.com/openshift/library-go@190fec8c3f09de1290c0dcaa25556b4515d65fc6 # different from e9762c6's @master $ go mod tidy $ go mod vendor $ sed -i 's|config/v1/0000_00_cluster-version-operator|config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator|g' $(git grep -l 0000_00_cluster-version-operator) $ sed -i 's/\(clusterversion\|clusteroperator\)/\1s/' hack/test-prerequisites.go $ git checkout a90cec9 -- pkg/payload/render.go # Eran Cohen's DevPreviewNoUpgrade exclusion $ git add -A Dockerfile* hack/test-prerequisites.go pkg/dependencymagnet pkg/featuregates go.* vendor all using: $ go version go version go1.22.2 linux/amd64 A few points on the invocation: * I usually use 'go get -u ...', e.g. a98232f (vendor: Bump openshift/api to pick up signatureStores, 2023-12-04, openshift#994), but in this case, that would pull in k8s.io/[email protected], and we want to stick with 0.29 until our release-4.16 branch stops following this development branch. * I'm explicitly bumping library-go, because if I don't, builds fail on [3]: Building github.com/openshift/cluster-version-operator (v1.0.0-1203-g258de3f7-dirty) # github.com/openshift/library-go/pkg/manifest vendor/github.com/openshift/library-go/pkg/manifest/manifest.go:32:35: undefined: configv1.FeatureSets # github.com/openshift/cluster-version-operator/pkg/featuregates pkg/featuregates/featuregates.go:92:32: undefined: configv1.FeatureGateUpgradeStatus pkg/featuregates/featuregates.go:97:33: undefined: configv1.FeatureGateUpgradeStatus If I had been able to use -u, library-go would have automatically floated to the tip commit anyway. But either way, I still needed to make manual changes to keep up with [4] moving to the new openshift/api/features package. * And I want [5], but for some reason: $ go get github.com/openshift/[email protected] github.com/openshift/[email protected] was getting me the older v0.0.0-20240517135010-e93e442c2b18. I'm not clear on why. But requesting the library-go commit I wanted by commit-hash instead of by branch-name got me the CustomNoUpgrade fix. * The DevPreviewNoUpgrade exclusion avoids bootstrap failures like [6]: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808/artifacts/e2e-aws-ovn-techpreview/ipi-install-install/artifacts/log-bundle-20240709194524.tar | tar -xOz log-bundle-20240709194524/bootstrap/journals/bootkube.log | grep 'are not consistent so results would be unpredictable depending on apply order' | tail -n4 Jul 09 19:45:15 ip-10-0-155-191 kube-apiserver-render[74584]: F0709 19:45:15.447834 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:15 ip-10-0-155-191 bootkube.sh[74561]: F0709 19:45:15.447834 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_cluster versions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:27 ip-10-0-155-191 kube-apiserver-render[75368]: F0709 19:45:27.669093 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_ 01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:27 ip-10-0-155-191 bootkube.sh[75345]: F0709 19:45:27.669093 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_cluster versions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values as the kube-apiserver-render command worries about the CVO having rendered two ClusterVersion CRDs: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808/artifacts/e2e-aws-ovn-techpre view/ipi-install-install/artifacts/log-bundle-20240709194524.tar | tar -tvz | grep 'cvo-bootstrap/.*cluster-version-operator.*crd' -rw-r--r-- core/core 42129 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml -rw-r--r-- core/core 39010 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml -rw-r--r-- core/core 7628 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusteroperators.crd.yaml [1]: openshift/api#1814 [2]: openshift/api@06baaa4#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5R211 [3]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-images/1785396933666279424#1:build-log.txt%3A74-79 [4]: openshift/api#1821 [5]: openshift/library-go#1759 Backported to 4.16 in openshift/library-go#1762 [6]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808
Like e9762c6 (vendor: Update openshift/api to pick up zz_generated.crd-manifests, 2024-04-30, openshift#1045), except I pulled release-4.16 branches. Catching up with the YAML getting shifted into a subdirectory [1]. I followed the new docs from [2] to create pkg/dependencymagnet, and then: $ emacs pkg/featuregates/featuregates.go pkg/featuregates/featurechangestopper_test.go # configv1.FeatureGateUpgradeStatus -> features.FeatureGateUpgradeStatus $ go get github.com/openshift/[email protected] github.com/openshift/library-go@190fec8c3f09de1290c0dcaa25556b4515d65fc6 # different from e9762c6's @master $ go mod tidy $ go mod vendor $ sed -i 's|config/v1/0000_00_cluster-version-operator|config/v1/zz_generated.crd-manifests/0000_00_cluster-version-operator|g' $(git grep -l 0000_00_cluster-version-operator) $ sed -i 's/\(clusterversion\|clusteroperator\)/\1s/' hack/test-prerequisites.go $ git checkout a90cec9 -- pkg/payload/render.go # Eran Cohen's DevPreviewNoUpgrade exclusion $ git add -A Dockerfile* hack/test-prerequisites.go pkg/dependencymagnet pkg/featuregates go.* vendor all using: $ go version go version go1.22.2 linux/amd64 A few points on the invocation: * I usually use 'go get -u ...', e.g. a98232f (vendor: Bump openshift/api to pick up signatureStores, 2023-12-04, openshift#994), but in this case, that would pull in k8s.io/[email protected], and we want to stick with 0.29 until our release-4.16 branch stops following this development branch. * I'm explicitly bumping library-go, because if I don't, builds fail on [3]: Building github.com/openshift/cluster-version-operator (v1.0.0-1203-g258de3f7-dirty) # github.com/openshift/library-go/pkg/manifest vendor/github.com/openshift/library-go/pkg/manifest/manifest.go:32:35: undefined: configv1.FeatureSets # github.com/openshift/cluster-version-operator/pkg/featuregates pkg/featuregates/featuregates.go:92:32: undefined: configv1.FeatureGateUpgradeStatus pkg/featuregates/featuregates.go:97:33: undefined: configv1.FeatureGateUpgradeStatus If I had been able to use -u, library-go would have automatically floated to the tip commit anyway. But either way, I still needed to make manual changes to keep up with [4] moving to the new openshift/api/features package. * And I want [5], but for some reason: $ go get github.com/openshift/[email protected] github.com/openshift/[email protected] was getting me the older v0.0.0-20240517135010-e93e442c2b18. I'm not clear on why. But requesting the library-go commit I wanted by commit-hash instead of by branch-name got me the CustomNoUpgrade fix. * The DevPreviewNoUpgrade exclusion avoids bootstrap failures like [6]: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808/artifacts/e2e-aws-ovn-techpreview/ipi-install-install/artifacts/log-bundle-20240709194524.tar | tar -xOz log-bundle-20240709194524/bootstrap/journals/bootkube.log | grep 'are not consistent so results would be unpredictable depending on apply order' | tail -n4 Jul 09 19:45:15 ip-10-0-155-191 kube-apiserver-render[74584]: F0709 19:45:15.447834 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:15 ip-10-0-155-191 bootkube.sh[74561]: F0709 19:45:15.447834 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_cluster versions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:27 ip-10-0-155-191 kube-apiserver-render[75368]: F0709 19:45:27.669093 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_ 01_clusterversions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values Jul 09 19:45:27 ip-10-0-155-191 bootkube.sh[75345]: F0709 19:45:27.669093 1 render.go:75] --rendered-manifest-files, are not consistent so results would be unpredictable depending on apply order: "/assets/manifests/0000_00_cluster-version-operator_01_cluster versions-DevPreviewNoUpgrade.crd.yaml" and "/assets/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml" both set CustomResourceDefinition.apiextensions.k8s.io/clusterversions.config.openshift.io in ns/, but have different values as the kube-apiserver-render command worries about the CVO having rendered two ClusterVersion CRDs: $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808/artifacts/e2e-aws-ovn-techpre view/ipi-install-install/artifacts/log-bundle-20240709194524.tar | tar -tvz | grep 'cvo-bootstrap/.*cluster-version-operator.*crd' -rw-r--r-- core/core 42129 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversions-DevPreviewNoUpgrade.crd.yaml -rw-r--r-- core/core 39010 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusterversions-Default.crd.yaml -rw-r--r-- core/core 7628 2024-07-09 12:45 log-bundle-20240709194524/rendered-assets/openshift/cvo-bootstrap/manifests/0000_00_cluster-version-operator_01_clusteroperators.crd.yaml [1]: openshift/api#1814 [2]: openshift/api@06baaa4#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5R211 [3]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-images/1785396933666279424#1:build-log.txt%3A74-79 [4]: openshift/api#1821 [5]: openshift/library-go#1759 Backported to 4.16 in openshift/library-go#1762 [6]: https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/openshift_cluster-version-operator/1045/pull-ci-openshift-cluster-version-operator-master-e2e-aws-ovn-techpreview/1810753819311607808
The verifier Interface's
AddStore
has always been:since it landed in 2020. We discussed then whether we were comfortable with "always insert the new addition serially in front of the existing stores", and decided that it was good enough then (although we neglected to commit to that implementation in the
Interface
's Go docs).That history sets up my approach in this commit where I add support for ClusterVersion's new
spec.signatureStores
. The logic is:signatureStores
.spec.signatureStores
, but with the default signature stores.We only fall through to the default stores when ConfigMap lookup is exhausted without finding a valid signature and
signatureStores
is unset, to support admins who would rather not have the cluster-version operator reach out to one or more of the default stores, whether or not they have local stores they would rather use. This allows admins to construct the set of stores they would like to use, while keeping the API surface down at a single property.Without the
AddStore
history, it would have been possible to construct simplified stores, like a ConfigMaps store alone in the case wheresignatureStores
is an empty array. We could still pivot to that kind of approach with library-go changes, but for the initial implementation, I'm doing the above dance to work withAddStore
as it stands.