From f80135a75764f5130ed42d8e16d82271abbfdac0 Mon Sep 17 00:00:00 2001 From: Feny Mehta Date: Thu, 19 Sep 2024 17:37:41 +0530 Subject: [PATCH 1/5] KUBESAW-187: Have a unique label for our operators (#597) * KUBESAW-170: Have a unique label for our operators Signed-off-by: Feny Mehta * add unique names instead of replacing it Signed-off-by: Feny Mehta --------- Signed-off-by: Feny Mehta --- config/manager/manager.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/config/manager/manager.yaml b/config/manager/manager.yaml index b767d504..3c9ca780 100644 --- a/config/manager/manager.yaml +++ b/config/manager/manager.yaml @@ -3,6 +3,7 @@ kind: Namespace metadata: labels: control-plane: controller-manager + kubesaw-control-plane: kubesaw-controller-manager name: system --- apiVersion: apps/v1 @@ -12,17 +13,20 @@ metadata: namespace: system labels: control-plane: controller-manager + kubesaw-control-plane: kubesaw-controller-manager annotations: kubectl.kubernetes.io/default-container: manager spec: selector: matchLabels: control-plane: controller-manager + kubesaw-control-plane: kubesaw-controller-manager replicas: 1 template: metadata: labels: control-plane: controller-manager + kubesaw-control-plane: kubesaw-controller-manager spec: securityContext: runAsNonRoot: true From 7e4e153d806ba0aaa1d4f5eebb9029fc9c7f0288 Mon Sep 17 00:00:00 2001 From: Francisc Munteanu Date: Wed, 25 Sep 2024 08:48:41 +0200 Subject: [PATCH 2/5] feat: Update NSTemplateSet CRD (#596) * add templates references to nstemplateset status --- ...hain.dev.openshift.com_nstemplatesets.yaml | 62 +++++++++++++++++++ 1 file changed, 62 insertions(+) diff --git a/config/crd/bases/toolchain.dev.openshift.com_nstemplatesets.yaml b/config/crd/bases/toolchain.dev.openshift.com_nstemplatesets.yaml index 3d25a8fd..f75efd75 100644 --- a/config/crd/bases/toolchain.dev.openshift.com_nstemplatesets.yaml +++ b/config/crd/bases/toolchain.dev.openshift.com_nstemplatesets.yaml @@ -108,6 +108,18 @@ spec: status: description: NSTemplateSetStatus defines the observed state of NSTemplateSet properties: + clusterResources: + description: The cluster resources template (for cluster-wide quotas, + etc.) that was used last time to provision the NSTemplateSet CR + properties: + templateRef: + description: TemplateRef The name of the TierTemplate resource + which exists in the host cluster and which contains the template + to use + type: string + required: + - templateRef + type: object conditions: description: 'Conditions is an array of current NSTemplateSet conditions Supported condition types: ConditionReady' @@ -143,6 +155,31 @@ spec: x-kubernetes-list-map-keys: - type x-kubernetes-list-type: map + featureToggles: + description: FeatureToggles holds the list of feature toggles/flags + that were enabled when the NSTemplateSet CR was provisioned for + the last time + items: + type: string + type: array + x-kubernetes-list-type: atomic + namespaces: + description: The namespace templates that were used last time to provision + NSTemplateSet CR + items: + description: NSTemplateSetNamespace the namespace definition in + an NSTemplateSet resource + properties: + templateRef: + description: TemplateRef The name of the TierTemplate resource + which exists in the host cluster and which contains the template + to use + type: string + required: + - templateRef + type: object + type: array + x-kubernetes-list-type: atomic provisionedNamespaces: description: ProvisionedNamespaces is a list of Namespaces that were provisioned by the NSTemplateSet. @@ -160,6 +197,31 @@ spec: type: object type: array x-kubernetes-list-type: atomic + spaceRoles: + description: The SpaceRole template and the users to whom the template + was applied for when the NSTemplateSet CR was provisioned for the + last time + items: + description: NSTemplateSetSpaceRole the role template and the users + to whom the templates should be applied to + properties: + templateRef: + description: TemplateRef The name of the TierTemplate resource + which exists in the host cluster and which contains the template + to use + type: string + usernames: + description: Usernames the usernames to which the template applies + items: + type: string + type: array + x-kubernetes-list-type: atomic + required: + - templateRef + - usernames + type: object + type: array + x-kubernetes-list-type: atomic type: object type: object x-kubernetes-preserve-unknown-fields: true From 5a67baec7ffadc583a319507e8930801a0dc0cd7 Mon Sep 17 00:00:00 2001 From: Feny Mehta Date: Mon, 30 Sep 2024 14:29:30 +0530 Subject: [PATCH 3/5] KUBESAW-192: Introduce a make command for pre-requisite of verify-replace (#599) Signed-off-by: Feny Mehta --- make/go.mk | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/make/go.mk b/make/go.mk index 679f2c72..3b617368 100644 --- a/make/go.mk +++ b/make/go.mk @@ -38,7 +38,7 @@ generate-assets: go-bindata .PHONY: verify-dependencies ## Runs commands to verify after the updated dependecies of toolchain-common/API(go mod replace), if the repo needs any changes to be made -verify-dependencies: generate-assets tidy vet build test lint-go-code +verify-dependencies: tidy vet build test lint-go-code .PHONY: tidy tidy: @@ -47,3 +47,7 @@ tidy: .PHONY: vet vet: go vet ./... + +.PHONY: pre-verify +pre-verify: generate-assets + echo "Pre-requisite completed" \ No newline at end of file From 6ca78c47e11a7140a1f2e61a9b7a490506b79bc9 Mon Sep 17 00:00:00 2001 From: Francisc Munteanu Date: Mon, 30 Sep 2024 13:51:31 +0200 Subject: [PATCH 4/5] bump api (#600) Co-authored-by: Devtools --- go.mod | 2 +- go.sum | 7 ++----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/go.mod b/go.mod index 618df5f0..71821487 100644 --- a/go.mod +++ b/go.mod @@ -1,7 +1,7 @@ module github.com/codeready-toolchain/member-operator require ( - github.com/codeready-toolchain/api v0.0.0-20240815232340-d0c164a83d27 + github.com/codeready-toolchain/api v0.0.0-20240927104325-b5bfcb3cb1b0 github.com/codeready-toolchain/toolchain-common v0.0.0-20240905135929-d55d86fdd41e github.com/go-logr/logr v1.2.3 github.com/google/go-cmp v0.5.9 diff --git a/go.sum b/go.sum index 17d3ce41..7c365361 100644 --- a/go.sum +++ b/go.sum @@ -134,10 +134,8 @@ github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWH github.com/cockroachdb/datadriven v0.0.0-20200714090401-bf6692d28da5/go.mod h1:h6jFvWxBdQXxjopDMZyH2UVceIRfR84bdzbkoKrsWNo= github.com/cockroachdb/errors v1.2.4/go.mod h1:rQD95gz6FARkaKkQXUksEje/d9a6wBJoCr5oaCLELYA= github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f/go.mod h1:i/u985jwjWRlyHXQbwatDASoW0RMlZ/3i9yJHE2xLkI= -github.com/codeready-toolchain/api v0.0.0-20240815232340-d0c164a83d27 h1:uEH8HAM81QZBccuqQpGKJUoJQe28+DFSYi/mRKZDYrA= -github.com/codeready-toolchain/api v0.0.0-20240815232340-d0c164a83d27/go.mod h1:ie9p4LenCCS0LsnbWp6/xwpFDdCWYE0KWzUO6Sk1g0E= -github.com/codeready-toolchain/toolchain-common v0.0.0-20240816011540-2184e6268b4a h1:o18wLp3eT4HdH8TvDqtLWiC47WY/kaTp9p54exux/MU= -github.com/codeready-toolchain/toolchain-common v0.0.0-20240816011540-2184e6268b4a/go.mod h1:aIbki5CFsykeqZn2/ZwvUb3Krx2f2Tbq58R6MGnk6H8= +github.com/codeready-toolchain/api v0.0.0-20240927104325-b5bfcb3cb1b0 h1:7cXHlRpoi1Owo8fYawl80PUsVWz+9AtMge6OJ4DjvWU= +github.com/codeready-toolchain/api v0.0.0-20240927104325-b5bfcb3cb1b0/go.mod h1:ie9p4LenCCS0LsnbWp6/xwpFDdCWYE0KWzUO6Sk1g0E= github.com/codeready-toolchain/toolchain-common v0.0.0-20240905135929-d55d86fdd41e h1:xTqyuImyon/P2QfV5NIJDsVkEWqb9b6Ax9INsmzpI1Q= github.com/codeready-toolchain/toolchain-common v0.0.0-20240905135929-d55d86fdd41e/go.mod h1:aIbki5CFsykeqZn2/ZwvUb3Krx2f2Tbq58R6MGnk6H8= github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= @@ -1141,7 +1139,6 @@ gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= From ab0ab11ffd4b4dfd2af83bbeb7af6475457fe2f6 Mon Sep 17 00:00:00 2001 From: Xavier Coulon Date: Mon, 30 Sep 2024 19:57:30 +0200 Subject: [PATCH 5/5] chore: remove Shane from CODEOWNERS (#601) Shane left the team Signed-off-by: Xavier Coulon --- CODEOWNERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CODEOWNERS b/CODEOWNERS index 629180bd..b6e88321 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -1 +1 @@ -* @MatousJobanek @xcoulon @alexeykazakov @rajivnathan @ranakan19 @sbryzak @mfrancisc +* @MatousJobanek @xcoulon @alexeykazakov @rajivnathan @ranakan19 @mfrancisc