From 0e494a107d7757e461409979c34734cc9c22f123 Mon Sep 17 00:00:00 2001 From: Melissa Lee Date: Thu, 25 Jul 2024 06:54:46 -0700 Subject: [PATCH] Update to Kustomize v5 --- Makefile | 4 +- ...ntime-component.clusterserviceversion.yaml | 10 +- config/crd/kustomization.yaml | 6 +- config/default/kustomization.yaml | 6 +- config/kubectl/operator/kustomization.yaml | 56 +++---- .../kubectl/rbac-watch-all/kustomization.yaml | 110 ++++++------ .../rbac-watch-another/kustomization.yaml | 64 ++++--- config/kustomize/crd/kustomization.yaml | 2 +- config/kustomize/operator/kustomization.yaml | 6 +- config/kustomize/watch-all/kustomization.yaml | 156 +++++++++--------- .../watch-another/kustomization.yaml | 90 +++++----- config/manager/manager.yaml | 4 +- config/manifests/kustomization.yaml | 3 +- config/manifests/patches/csvAnnotations.yaml | 4 +- .../rc.app.stacks_v1_runtimecomponent.yaml | 2 +- ...c.app.stacks_v1beta2_runtimecomponent.yaml | 2 +- config/scorecard/kustomization.yaml | 3 +- .../kubectl/runtime-component-operator.yaml | 6 +- .../runtime-component-rbac-watch-all.yaml | 8 - .../base/runtime-component-operator.yaml | 2 +- 20 files changed, 263 insertions(+), 281 deletions(-) diff --git a/Makefile b/Makefile index 3fe76d05d..336683bd3 100644 --- a/Makefile +++ b/Makefile @@ -147,12 +147,12 @@ CONTROLLER_GEN ?= $(LOCALBIN)/controller-gen ENVTEST ?= $(LOCALBIN)/setup-envtest ## Tool Versions -KUSTOMIZE_VERSION ?= 4.5.5 +KUSTOMIZE_VERSION ?= 5.4.2 KUSTOMIZE_INSTALL_SCRIPT ?= "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/kustomize/v${KUSTOMIZE_VERSION}/hack/install_kustomize.sh" .PHONY: kustomize kustomize: $(KUSTOMIZE) ## Download kustomize locally if necessary. $(KUSTOMIZE): $(LOCALBIN) - test -s $(LOCALBIN)/kustomize || curl -s $(KUSTOMIZE_INSTALL_SCRIPT) | bash -s $(KUSTOMIZE_VERSION) $(LOCALBIN) + test -s $(LOCALBIN)/kustomize || GOBIN=$(LOCALBIN) GO111MODULE=on go install sigs.k8s.io/kustomize/kustomize/v5@v$(KUSTOMIZE_VERSION) CONTROLLER_TOOLS_VERSION ?= 0.14.0 .PHONY: controller-gen diff --git a/bundle/manifests/runtime-component.clusterserviceversion.yaml b/bundle/manifests/runtime-component.clusterserviceversion.yaml index b9838cb4e..b1829dd2e 100644 --- a/bundle/manifests/runtime-component.clusterserviceversion.yaml +++ b/bundle/manifests/runtime-component.clusterserviceversion.yaml @@ -11,7 +11,7 @@ metadata: "name": "runtimecomponent-sample" }, "spec": { - "applicationImage": "icr.io/appcafe/open-liberty/samples/getting-started@sha256:fd04ce5a5870387a379b54da5c47d0338c5f4a1254611d2418f1f959d018ba7e", + "applicationImage": "icr.io/appcafe/open-liberty/samples/getting-started@sha256:422a7a00edc338497c0a91890b09204b8505ef0e377bb9b5944ace0102055e91", "expose": true, "manageTLS": true, "replicas": 1, @@ -44,7 +44,7 @@ metadata: "name": "runtimecomponent-sample" }, "spec": { - "applicationImage": "icr.io/appcafe/open-liberty/samples/getting-started@sha256:fd04ce5a5870387a379b54da5c47d0338c5f4a1254611d2418f1f959d018ba7e", + "applicationImage": "icr.io/appcafe/open-liberty/samples/getting-started@sha256:422a7a00edc338497c0a91890b09204b8505ef0e377bb9b5944ace0102055e91", "expose": true, "replicas": 1, "service": { @@ -71,7 +71,7 @@ metadata: categories: Application Runtime certified: "true" containerImage: icr.io/appcafe/runtime-component-operator:daily - createdAt: "2024-07-11T19:05:26Z" + createdAt: "2024-07-25T13:54:09Z" description: Deploys any runtime component with dynamic and auto-tuning configuration olm.skipRange: '>=0.8.0 <1.3.2' operators.openshift.io/infrastructure-features: '["disconnected"]' @@ -1012,7 +1012,7 @@ spec: fieldRef: fieldPath: metadata.annotations['olm.targetNamespaces'] - name: RELATED_IMAGE_LIBERTY_SAMPLE_APP - value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:fd04ce5a5870387a379b54da5c47d0338c5f4a1254611d2418f1f959d018ba7e + value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:422a7a00edc338497c0a91890b09204b8505ef0e377bb9b5944ace0102055e91 - name: RELATED_IMAGE_RUNTIME_COMPONENT_OPERATOR value: icr.io/appcafe/runtime-component-operator:daily image: icr.io/appcafe/runtime-component-operator:daily @@ -1295,7 +1295,7 @@ spec: provider: name: Community relatedImages: - - image: icr.io/appcafe/open-liberty/samples/getting-started@sha256:fd04ce5a5870387a379b54da5c47d0338c5f4a1254611d2418f1f959d018ba7e + - image: icr.io/appcafe/open-liberty/samples/getting-started@sha256:422a7a00edc338497c0a91890b09204b8505ef0e377bb9b5944ace0102055e91 name: liberty-sample-app - image: icr.io/appcafe/runtime-component-operator:daily name: runtime-component-operator diff --git a/config/crd/kustomization.yaml b/config/crd/kustomization.yaml index f9cce349b..707f4291e 100644 --- a/config/crd/kustomization.yaml +++ b/config/crd/kustomization.yaml @@ -6,7 +6,7 @@ resources: - bases/rc.app.stacks_runtimeoperations.yaml # +kubebuilder:scaffold:crdkustomizeresource -patchesStrategicMerge: +patches: # [WEBHOOK] To enable webhook, uncomment all the sections with [WEBHOOK] prefix. # patches here are for enabling the conversion webhook for each CRD #- patches/webhook_in_runtimecomponents.yaml @@ -19,8 +19,8 @@ patchesStrategicMerge: #- patches/cainjection_in_runtimeoperations.yaml # +kubebuilder:scaffold:crdkustomizecainjectionpatch -- patches/preserveUnknownFields_runtimecomponents.yaml -- patches/preserveUnknownFields_runtimeoperations.yaml +- path: patches/preserveUnknownFields_runtimecomponents.yaml +- path: patches/preserveUnknownFields_runtimeoperations.yaml # +kubebuilder:scaffold:preserveunknownfieldspatch # the following config is for teaching kustomize how to do kustomization for CRDs. diff --git a/config/default/kustomization.yaml b/config/default/kustomization.yaml index 79e16b78c..99a4a44d1 100644 --- a/config/default/kustomization.yaml +++ b/config/default/kustomization.yaml @@ -14,7 +14,7 @@ commonLabels: app.kubernetes.io/managed-by: olm app.kubernetes.io/name: runtime-component-operator -bases: +resources: - ../crd - ../rbac - ../manager @@ -26,7 +26,7 @@ bases: # [PROMETHEUS] To enable prometheus monitor, uncomment all sections with 'PROMETHEUS'. #- ../prometheus -patchesStrategicMerge: +# patches: # Protect the /metrics endpoint by putting it behind auth. # If you want your controller-manager to expose the /metrics # endpoint w/o any authn/z, please comment the following line. @@ -42,7 +42,7 @@ patchesStrategicMerge: #- webhookcainjection_patch.yaml # the following config is for teaching kustomize how to do var substitution -vars: +# vars: # [CERTMANAGER] To enable cert-manager, uncomment all sections with 'CERTMANAGER' prefix. #- name: CERTIFICATE_NAMESPACE # namespace of the certificate CR # objref: diff --git a/config/kubectl/operator/kustomization.yaml b/config/kubectl/operator/kustomization.yaml index b12c84bb7..ebee29392 100644 --- a/config/kubectl/operator/kustomization.yaml +++ b/config/kubectl/operator/kustomization.yaml @@ -15,32 +15,30 @@ patches: - path: patches/delete-namespace.yaml target: kind: Namespace - -patchesJson6902: - - target: - namespace: system - name: .* - patch: |- - - op: remove - path: /metadata/namespace - - target: - namespace: runtime-component-operator - name: .* - patch: |- - - op: remove - path: /metadata/namespace - - target: - kind: RoleBinding - name: .* - patch: |- - - op: remove - path: /subjects/0/namespace - - target: - kind: Deployment - name: rco-controller-manager - patch: |- - - op: remove - path: /spec/template/spec/containers/0/env/1/valueFrom - - op: add - path: /spec/template/spec/containers/0/env/1/value - value: RUNTIME_COMPONENT_WATCH_NAMESPACE \ No newline at end of file +- target: + namespace: system + name: .* + patch: |- + - op: remove + path: /metadata/namespace +- target: + namespace: runtime-component-operator + name: .* + patch: |- + - op: remove + path: /metadata/namespace +- target: + kind: RoleBinding + name: .* + patch: |- + - op: remove + path: /subjects/0/namespace +- target: + kind: Deployment + name: rco-controller-manager + patch: |- + - op: remove + path: /spec/template/spec/containers/0/env/1/valueFrom + - op: add + path: /spec/template/spec/containers/0/env/1/value + value: RUNTIME_COMPONENT_WATCH_NAMESPACE \ No newline at end of file diff --git a/config/kubectl/rbac-watch-all/kustomization.yaml b/config/kubectl/rbac-watch-all/kustomization.yaml index 67c0b1fdd..669787f77 100644 --- a/config/kubectl/rbac-watch-all/kustomization.yaml +++ b/config/kubectl/rbac-watch-all/kustomization.yaml @@ -14,59 +14,57 @@ patches: - path: patches/delete-service-account.yaml target: kind: ServiceAccount - -patchesJson6902: - - target: - namespace: runtime-component-operator - name: .* - patch: |- - - op: remove - path: /metadata/namespace - - target: - kind: Role - name: .* - patch: |- - - op: replace - path: /kind - value: ClusterRole - - target: - kind: RoleBinding - name: .* - patch: |- - - op: replace - path: /kind - value: ClusterRoleBinding - - target: - kind: ClusterRoleBinding - name: .* - patch: |- - - op: replace - path: /subjects/0/name - value: rco-controller-manager - - op: replace - path: /subjects/0/namespace - value: RUNTIME_COMPONENT_OPERATOR_NAMESPACE - - op: replace - path: /roleRef/kind - value: ClusterRole - - target: - kind: ClusterRoleBinding - name: rco-cluster-leader-election-rolebinding - patch: |- - - op: replace - path: /roleRef/name - value: rco-cluster-leader-election-role - - target: - kind: ClusterRoleBinding - name: rco-cluster-manager-rolebinding - patch: |- - - op: replace - path: /roleRef/name - value: rco-cluster-manager-role - - target: - kind: ClusterRole - name: rco-cluster-manager-role - patch: |- - - op: add - path: /rules/- - value: {"apiGroups":[""],"resources":["namespaces"],"verbs":["get","list","watch"]} \ No newline at end of file +- target: + namespace: runtime-component-operator + name: .* + patch: |- + - op: remove + path: /metadata/namespace +- target: + kind: Role + name: .* + patch: |- + - op: replace + path: /kind + value: ClusterRole +- target: + kind: RoleBinding + name: .* + patch: |- + - op: replace + path: /kind + value: ClusterRoleBinding +- target: + kind: ClusterRoleBinding + name: .* + patch: |- + - op: replace + path: /subjects/0/name + value: rco-controller-manager + - op: replace + path: /subjects/0/namespace + value: RUNTIME_COMPONENT_OPERATOR_NAMESPACE + - op: replace + path: /roleRef/kind + value: ClusterRole +- target: + kind: ClusterRoleBinding + name: rco-cluster-leader-election-rolebinding + patch: |- + - op: replace + path: /roleRef/name + value: rco-cluster-leader-election-role +- target: + kind: ClusterRoleBinding + name: rco-cluster-manager-rolebinding + patch: |- + - op: replace + path: /roleRef/name + value: rco-cluster-manager-role +- target: + kind: ClusterRole + name: rco-cluster-manager-role + patch: |- + - op: add + path: /rules/- + value: {"apiGroups":[""],"resources":["namespaces"],"verbs":["get","list","watch"]} \ No newline at end of file diff --git a/config/kubectl/rbac-watch-another/kustomization.yaml b/config/kubectl/rbac-watch-another/kustomization.yaml index 37d825ec5..c366abf88 100644 --- a/config/kubectl/rbac-watch-another/kustomization.yaml +++ b/config/kubectl/rbac-watch-another/kustomization.yaml @@ -14,37 +14,35 @@ patches: - path: patches/delete-service-account.yaml target: kind: ServiceAccount +- target: + name: .* + patch: |- + - op: replace + path: /metadata/namespace + value: RUNTIME_COMPONENT_WATCH_NAMESPACE +- target: + kind: RoleBinding + name: .* + patch: |- + - op: replace + path: /subjects/0/namespace + value: RUNTIME_COMPONENT_OPERATOR_NAMESPACE + - op: replace + path: /subjects/0/name + value: rco-controller-manager +- target: + kind: RoleBinding + name: rco-watched-leader-election-rolebinding + patch: |- + - op: replace + path: /roleRef/name + value: rco-watched-leader-election-role +- target: + kind: RoleBinding + name: rco-watched-manager-rolebinding + patch: |- + - op: replace + path: /roleRef/name + value: rco-watched-manager-role -patchesJson6902: - - target: - name: .* - patch: |- - - op: replace - path: /metadata/namespace - value: RUNTIME_COMPONENT_WATCH_NAMESPACE - - target: - kind: RoleBinding - name: .* - patch: |- - - op: replace - path: /subjects/0/namespace - value: RUNTIME_COMPONENT_OPERATOR_NAMESPACE - - op: replace - path: /subjects/0/name - value: rco-controller-manager - - target: - kind: RoleBinding - name: rco-watched-leader-election-rolebinding - patch: |- - - op: replace - path: /roleRef/name - value: rco-watched-leader-election-role - - target: - kind: RoleBinding - name: rco-watched-manager-rolebinding - patch: |- - - op: replace - path: /roleRef/name - value: rco-watched-manager-role - - \ No newline at end of file + \ No newline at end of file diff --git a/config/kustomize/crd/kustomization.yaml b/config/kustomize/crd/kustomization.yaml index 8f56e473d..37b6118a0 100644 --- a/config/kustomize/crd/kustomization.yaml +++ b/config/kustomize/crd/kustomization.yaml @@ -3,5 +3,5 @@ commonLabels: app.kubernetes.io/instance: runtime-component-operator app.kubernetes.io/name: runtime-component-operator -bases: +resources: - ../../crd \ No newline at end of file diff --git a/config/kustomize/operator/kustomization.yaml b/config/kustomize/operator/kustomization.yaml index 3ae5bbd10..5c83b4b82 100644 --- a/config/kustomize/operator/kustomization.yaml +++ b/config/kustomize/operator/kustomization.yaml @@ -12,6 +12,6 @@ commonLabels: app.kubernetes.io/instance: runtime-component-operator app.kubernetes.io/name: runtime-component-operator -patchesStrategicMerge: -- patches/delete-namespace.yaml -- patches/watch-namespace.yaml +patches: +- path: patches/delete-namespace.yaml +- path: patches/watch-namespace.yaml diff --git a/config/kustomize/watch-all/kustomization.yaml b/config/kustomize/watch-all/kustomization.yaml index bb4a9fb8b..aca6a2158 100644 --- a/config/kustomize/watch-all/kustomization.yaml +++ b/config/kustomize/watch-all/kustomization.yaml @@ -12,82 +12,80 @@ patches: - path: patches/delete-service-account.yaml target: kind: ServiceAccount - -patchesJson6902: - - target: - namespace: runtime-component-operator - name: .* - patch: |- - - op: remove - path: /metadata/namespace - - target: - kind: Role - name: .* - patch: |- - - op: replace - path: /kind - value: ClusterRole - - target: - kind: RoleBinding - name: .* - patch: |- - - op: replace - path: /kind - value: ClusterRoleBinding - - target: - kind: ClusterRoleBinding - name: .* - patch: |- - - op: replace - path: /subjects/0/name - value: rco-controller-manager - - op: replace - path: /subjects/0/namespace - value: RUNTIME_COMPONENT_OPERATOR_NAMESPACE - - op: replace - path: /roleRef/kind - value: ClusterRole - - target: - kind: ClusterRoleBinding - name: leader-election-rolebinding - patch: |- - - op: replace - path: /roleRef/name - value: rco-leader-election-cluster-role - - op: replace - path: /metadata/name - value: rco-leader-election-cluster-rolebinding - - target: - kind: ClusterRoleBinding - name: manager-rolebinding - patch: |- - - op: replace - path: /metadata/name - value: rco-manager-cluster-rolebinding - - op: replace - path: /roleRef/name - value: rco-manager-cluster-role - - target: - kind: ClusterRole - name: manager-role - patch: |- - - op: replace - path: /metadata/name - value: rco-manager-cluster-role - - op: add - path: /rules/- - value: {"apiGroups":[""],"resources":["namespaces"],"verbs":["get","list","watch"]} - - target: - kind: ClusterRoleBinding - name: .* - patch: |- - - op: replace - path: /subjects/0/namespace - value: runtime-component - - target: - kind: ClusterRole - name: leader-election-role - patch: |- - - op: replace - path: /metadata/name - value: rco-leader-election-cluster-role \ No newline at end of file +- target: + namespace: runtime-component-operator + name: .* + patch: |- + - op: remove + path: /metadata/namespace +- target: + kind: Role + name: .* + patch: |- + - op: replace + path: /kind + value: ClusterRole +- target: + kind: RoleBinding + name: .* + patch: |- + - op: replace + path: /kind + value: ClusterRoleBinding +- target: + kind: ClusterRoleBinding + name: .* + patch: |- + - op: replace + path: /subjects/0/name + value: rco-controller-manager + - op: replace + path: /subjects/0/namespace + value: RUNTIME_COMPONENT_OPERATOR_NAMESPACE + - op: replace + path: /roleRef/kind + value: ClusterRole +- target: + kind: ClusterRoleBinding + name: leader-election-rolebinding + patch: |- + - op: replace + path: /roleRef/name + value: rco-leader-election-cluster-role + - op: replace + path: /metadata/name + value: rco-leader-election-cluster-rolebinding +- target: + kind: ClusterRoleBinding + name: manager-rolebinding + patch: |- + - op: replace + path: /metadata/name + value: rco-manager-cluster-rolebinding + - op: replace + path: /roleRef/name + value: rco-manager-cluster-role +- target: + kind: ClusterRole + name: manager-role + patch: |- + - op: replace + path: /metadata/name + value: rco-manager-cluster-role + - op: add + path: /rules/- + value: {"apiGroups":[""],"resources":["namespaces"],"verbs":["get","list","watch"]} +- target: + kind: ClusterRoleBinding + name: .* + patch: |- + - op: replace + path: /subjects/0/namespace + value: runtime-component +- target: + kind: ClusterRole + name: leader-election-role + patch: |- + - op: replace + path: /metadata/name + value: rco-leader-election-cluster-role \ No newline at end of file diff --git a/config/kustomize/watch-another/kustomization.yaml b/config/kustomize/watch-another/kustomization.yaml index cada7d37a..2d889deac 100644 --- a/config/kustomize/watch-another/kustomization.yaml +++ b/config/kustomize/watch-another/kustomization.yaml @@ -14,49 +14,47 @@ patches: - path: patches/delete-service-account.yaml target: kind: ServiceAccount - -patchesJson6902: - - target: - kind: RoleBinding - name: manager-rolebinding - patch: |- - - op: replace - path: /metadata/name - value: rco-watched-rolebinding - - op: replace - path: /roleRef/name - value: rco-watched-role - - target: - kind: RoleBinding - name: leader-election-rolebinding - patch: |- - - op: replace - path: /metadata/name - value: rco-leader-election-watched-rolebinding - - op: replace - path: /roleRef/name - value: rco-leader-election-watched-role - - target: - kind: RoleBinding - name: .* - patch: |- - - op: replace - path: /subjects/0/namespace - value: rco-ns - - op: replace - path: /subjects/0/name - value: rco-controller-manager - - target: - kind: Role - name: leader-election-role - patch: |- - - op: replace - path: /metadata/name - value: rco-leader-election-watched-role - - target: - kind: Role - name: manager-role - patch: |- - - op: replace - path: /metadata/name - value: rco-watched-role \ No newline at end of file +- target: + kind: RoleBinding + name: manager-rolebinding + patch: |- + - op: replace + path: /metadata/name + value: rco-watched-rolebinding + - op: replace + path: /roleRef/name + value: rco-watched-role +- target: + kind: RoleBinding + name: leader-election-rolebinding + patch: |- + - op: replace + path: /metadata/name + value: rco-leader-election-watched-rolebinding + - op: replace + path: /roleRef/name + value: rco-leader-election-watched-role +- target: + kind: RoleBinding + name: .* + patch: |- + - op: replace + path: /subjects/0/namespace + value: rco-ns + - op: replace + path: /subjects/0/name + value: rco-controller-manager +- target: + kind: Role + name: leader-election-role + patch: |- + - op: replace + path: /metadata/name + value: rco-leader-election-watched-role +- target: + kind: Role + name: manager-role + patch: |- + - op: replace + path: /metadata/name + value: rco-watched-role \ No newline at end of file diff --git a/config/manager/manager.yaml b/config/manager/manager.yaml index 0894650bf..cca557e1a 100644 --- a/config/manager/manager.yaml +++ b/config/manager/manager.yaml @@ -67,9 +67,9 @@ spec: fieldRef: fieldPath: metadata.annotations['olm.targetNamespaces'] - name: RELATED_IMAGE_LIBERTY_SAMPLE_APP - value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:fd04ce5a5870387a379b54da5c47d0338c5f4a1254611d2418f1f959d018ba7e + value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:422a7a00edc338497c0a91890b09204b8505ef0e377bb9b5944ace0102055e91 - name: RELATED_IMAGE_RUNTIME_COMPONENT_OPERATOR - value: OPERATOR_IMAGE + value: icr.io/appcafe/runtime-component-operator:daily securityContext: allowPrivilegeEscalation: false privileged: false diff --git a/config/manifests/kustomization.yaml b/config/manifests/kustomization.yaml index 888a70a05..4daf6ff7c 100644 --- a/config/manifests/kustomization.yaml +++ b/config/manifests/kustomization.yaml @@ -5,9 +5,8 @@ resources: - ../default - ../samples - ../scorecard -patchesStrategicMerge: -- patches/csvAnnotations.yaml patches: +- path: patches/csvAnnotations.yaml - path: serviceBindingPatch.yaml target: kind: ClusterServiceVersion diff --git a/config/manifests/patches/csvAnnotations.yaml b/config/manifests/patches/csvAnnotations.yaml index 908ff4f29..7c23c93ab 100644 --- a/config/manifests/patches/csvAnnotations.yaml +++ b/config/manifests/patches/csvAnnotations.yaml @@ -4,5 +4,5 @@ metadata: name: runtime-component.v0.0.0 namespace: placeholder annotations: - containerImage: IMAGE - createdAt: CREATEDAT \ No newline at end of file + containerImage: icr.io/appcafe/runtime-component-operator:daily + createdAt: 2024-07-25T06:52:09Z \ No newline at end of file diff --git a/config/samples/rc.app.stacks_v1_runtimecomponent.yaml b/config/samples/rc.app.stacks_v1_runtimecomponent.yaml index 735a17ace..f078afe22 100644 --- a/config/samples/rc.app.stacks_v1_runtimecomponent.yaml +++ b/config/samples/rc.app.stacks_v1_runtimecomponent.yaml @@ -3,7 +3,7 @@ kind: RuntimeComponent metadata: name: runtimecomponent-sample spec: - applicationImage: icr.io/appcafe/open-liberty/samples/getting-started@sha256:fd04ce5a5870387a379b54da5c47d0338c5f4a1254611d2418f1f959d018ba7e + applicationImage: icr.io/appcafe/open-liberty/samples/getting-started@sha256:422a7a00edc338497c0a91890b09204b8505ef0e377bb9b5944ace0102055e91 expose: true manageTLS: true replicas: 1 diff --git a/config/samples/rc.app.stacks_v1beta2_runtimecomponent.yaml b/config/samples/rc.app.stacks_v1beta2_runtimecomponent.yaml index 6a5d0970e..ab06e1a58 100644 --- a/config/samples/rc.app.stacks_v1beta2_runtimecomponent.yaml +++ b/config/samples/rc.app.stacks_v1beta2_runtimecomponent.yaml @@ -4,7 +4,7 @@ metadata: name: runtimecomponent-sample spec: # Add fields here - applicationImage: icr.io/appcafe/open-liberty/samples/getting-started@sha256:fd04ce5a5870387a379b54da5c47d0338c5f4a1254611d2418f1f959d018ba7e + applicationImage: icr.io/appcafe/open-liberty/samples/getting-started@sha256:422a7a00edc338497c0a91890b09204b8505ef0e377bb9b5944ace0102055e91 expose: true replicas: 1 service: diff --git a/config/scorecard/kustomization.yaml b/config/scorecard/kustomization.yaml index d73509ee7..7fa711322 100644 --- a/config/scorecard/kustomization.yaml +++ b/config/scorecard/kustomization.yaml @@ -1,6 +1,6 @@ resources: - bases/config.yaml -patchesJson6902: +patches: - path: patches/basic.config.yaml target: group: scorecard.operatorframework.io @@ -13,4 +13,3 @@ patchesJson6902: version: v1alpha3 kind: Configuration name: config -# +kubebuilder:scaffold:patchesJson6902 diff --git a/internal/deploy/kubectl/runtime-component-operator.yaml b/internal/deploy/kubectl/runtime-component-operator.yaml index 780d74243..ad2c453b8 100644 --- a/internal/deploy/kubectl/runtime-component-operator.yaml +++ b/internal/deploy/kubectl/runtime-component-operator.yaml @@ -300,9 +300,11 @@ spec: fieldRef: fieldPath: metadata.namespace - name: WATCH_NAMESPACE - value: RUNTIME_COMPONENT_WATCH_NAMESPACE + valueFrom: + fieldRef: + fieldPath: metadata.annotations['olm.targetNamespaces'] - name: RELATED_IMAGE_LIBERTY_SAMPLE_APP - value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:fd04ce5a5870387a379b54da5c47d0338c5f4a1254611d2418f1f959d018ba7e + value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:422a7a00edc338497c0a91890b09204b8505ef0e377bb9b5944ace0102055e91 - name: RELATED_IMAGE_RUNTIME_COMPONENT_OPERATOR value: icr.io/appcafe/runtime-component-operator:daily image: icr.io/appcafe/runtime-component-operator:daily diff --git a/internal/deploy/kubectl/runtime-component-rbac-watch-all.yaml b/internal/deploy/kubectl/runtime-component-rbac-watch-all.yaml index 16077a594..89c505cb9 100644 --- a/internal/deploy/kubectl/runtime-component-rbac-watch-all.yaml +++ b/internal/deploy/kubectl/runtime-component-rbac-watch-all.yaml @@ -214,14 +214,6 @@ rules: - list - update - watch -- apiGroups: - - "" - resources: - - namespaces - verbs: - - get - - list - - watch --- apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRoleBinding diff --git a/internal/deploy/kustomize/daily/base/runtime-component-operator.yaml b/internal/deploy/kustomize/daily/base/runtime-component-operator.yaml index d962913a9..94ddc7a97 100644 --- a/internal/deploy/kustomize/daily/base/runtime-component-operator.yaml +++ b/internal/deploy/kustomize/daily/base/runtime-component-operator.yaml @@ -50,7 +50,7 @@ spec: fieldRef: fieldPath: metadata.namespace - name: RELATED_IMAGE_LIBERTY_SAMPLE_APP - value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:fd04ce5a5870387a379b54da5c47d0338c5f4a1254611d2418f1f959d018ba7e + value: icr.io/appcafe/open-liberty/samples/getting-started@sha256:422a7a00edc338497c0a91890b09204b8505ef0e377bb9b5944ace0102055e91 - name: RELATED_IMAGE_RUNTIME_COMPONENT_OPERATOR value: icr.io/appcafe/runtime-component-operator:daily image: icr.io/appcafe/runtime-component-operator:daily