From 55c445d777e2c91588ebbb9290434054dc99a067 Mon Sep 17 00:00:00 2001 From: Jan Larwig Date: Mon, 23 Nov 2026 15:36:17 +0100 Subject: [PATCH] refactor: use the shorthand name capstk for deployment name and namespace Signed-off-by: Jan Larwig --- config/default/kustomization.yaml | 4 ++-- docs/src/development/index.md | 6 +++--- docs/src/development/tilt-setup.md | 6 +++--- docs/src/quick-start.md | 6 +++--- test/e2e/e2e_test.go | 24 ++++++++++++------------ 5 files changed, 23 insertions(+), 23 deletions(-) diff --git a/config/default/kustomization.yaml b/config/default/kustomization.yaml index 66b6111..bc93f72 100644 --- a/config/default/kustomization.yaml +++ b/config/default/kustomization.yaml @@ -1,12 +1,12 @@ # Adds namespace to all resources. -namespace: cluster-api-provider-stackit-system +namespace: capstk-system # Value of this field is prepended to the # names of all resources, e.g. a deployment named # "wordpress" becomes "alices-wordpress". # Note that it should also match with the prefix (text before '-') of the namespace # field above. -namePrefix: cluster-api-provider-stackit- +namePrefix: capstk- # Labels to add to all resources and selectors. labels: diff --git a/docs/src/development/index.md b/docs/src/development/index.md index aec929c..5c8ec93 100644 --- a/docs/src/development/index.md +++ b/docs/src/development/index.md @@ -93,8 +93,8 @@ Wait until the locally built provider is ready: ```sh kubectl rollout status \ - --namespace cluster-api-provider-stackit-system \ - deployment/cluster-api-provider-stackit-controller-manager + --namespace capstk-system \ + deployment/capstk-controller-manager ``` ## Configure STACKIT and create a workload cluster @@ -184,7 +184,7 @@ If resources persist after several minutes: kubectl logs -n capi-system deployment/capi-controller-manager -c manager --tail=100 # STACKIT provider controller - kubectl logs -n cluster-api-provider-stackit-system deployment/cluster-api-provider-stackit-controller-manager --tail=100 + kubectl logs -n capstk-system deployment/capstk-controller-manager --tail=100 ``` 3. If a `StackitMachine` cannot finish deletion and blocks its parent resources, you can remove its finalizer: diff --git a/docs/src/development/tilt-setup.md b/docs/src/development/tilt-setup.md index 32ab3d3..91fa3e4 100644 --- a/docs/src/development/tilt-setup.md +++ b/docs/src/development/tilt-setup.md @@ -130,9 +130,9 @@ Tilt should deploy: Verify the provider pod: ```sh -kubectl get pods -n cluster-api-provider-stackit-system -kubectl logs -n cluster-api-provider-stackit-system \ - deployment/cluster-api-provider-stackit-controller-manager \ +kubectl get pods -n capstk-system +kubectl logs -n capstk-system \ + deployment/capstk-controller-manager \ -c manager ``` diff --git a/docs/src/quick-start.md b/docs/src/quick-start.md index 686e9d4..8c8a83f 100644 --- a/docs/src/quick-start.md +++ b/docs/src/quick-start.md @@ -71,8 +71,8 @@ Wait for the provider controller: ```sh kubectl rollout status \ - --namespace cluster-api-provider-stackit-system \ - deployment/cluster-api-provider-stackit-controller-manager + --namespace capstk-system \ + deployment/capstk-controller-manager ``` ## Set credentials and cluster settings @@ -207,7 +207,7 @@ If resources persist after several minutes: kubectl logs -n capi-system deployment/capi-controller-manager -c manager --tail=100 # STACKIT provider controller - kubectl logs -n cluster-api-provider-stackit-system deployment/cluster-api-provider-stackit-controller-manager --tail=100 + kubectl logs -n capstk-system deployment/capstk-controller-manager --tail=100 ``` 3. If a `StackitMachine` cannot finish deletion and blocks its parent resources, you can remove its finalizer: diff --git a/test/e2e/e2e_test.go b/test/e2e/e2e_test.go index 9c39078..ff21577 100644 --- a/test/e2e/e2e_test.go +++ b/test/e2e/e2e_test.go @@ -39,16 +39,16 @@ import ( ) // namespace where the project is deployed in -const namespace = "cluster-api-provider-stackit-system" +const namespace = "capstk-system" // serviceAccountName created for the project -const serviceAccountName = "cluster-api-provider-stackit-controller-manager" +const serviceAccountName = "capstk-controller-manager" // metricsServiceName is the name of the metrics service of the project -const metricsServiceName = "cluster-api-provider-stackit-controller-manager-metrics-service" +const metricsServiceName = "capstk-controller-manager-metrics-service" // metricsRoleBindingName is the name of the RBAC that will be created to allow get the metrics data -const metricsRoleBindingName = "cluster-api-provider-stackit-metrics-binding" +const metricsRoleBindingName = "capstk-metrics-binding" const stackitE2EMachineType = "c2i.2" @@ -96,10 +96,10 @@ var _ = Describe("Manager", Ordered, func() { Expect(err).NotTo(HaveOccurred(), "Failed to deploy the controller-manager") By("restarting the controller-manager to pick up the freshly loaded image") - cmd = exec.Command("kubectl", "rollout", "restart", "deployment/cluster-api-provider-stackit-controller-manager", "-n", namespace) + cmd = exec.Command("kubectl", "rollout", "restart", "deployment/capstk-controller-manager", "-n", namespace) _, err = utils.Run(cmd) Expect(err).NotTo(HaveOccurred(), "Failed to restart the controller-manager") - cmd = exec.Command("kubectl", "rollout", "status", "deployment/cluster-api-provider-stackit-controller-manager", "-n", namespace, "--timeout=5m") + cmd = exec.Command("kubectl", "rollout", "status", "deployment/capstk-controller-manager", "-n", namespace, "--timeout=5m") _, err = utils.Run(cmd) Expect(err).NotTo(HaveOccurred(), "controller-manager did not roll out") }) @@ -206,7 +206,7 @@ var _ = Describe("Manager", Ordered, func() { It("should ensure the metrics endpoint is serving metrics", func() { By("creating a ClusterRoleBinding for the service account to allow access to metrics") cmd := exec.Command("kubectl", "create", "clusterrolebinding", metricsRoleBindingName, - "--clusterrole=cluster-api-provider-stackit-metrics-reader", + "--clusterrole=capstk-metrics-reader", fmt.Sprintf("--serviceaccount=%s:%s", namespace, serviceAccountName), ) _, err := utils.Run(cmd) @@ -245,7 +245,7 @@ var _ = Describe("Manager", Ordered, func() { By("waiting for the webhook service endpoints to be ready") verifyWebhookEndpointsReady := func(g Gomega) { cmd := exec.Command("kubectl", "get", "endpointslices.discovery.k8s.io", "-n", namespace, - "-l", "kubernetes.io/service-name=cluster-api-provider-stackit-webhook-service", + "-l", "kubernetes.io/service-name=capstk-webhook-service", "-o", "jsonpath={range .items[*]}{range .endpoints[*]}{.addresses[*]}{end}{end}") output, err := utils.Run(cmd) g.Expect(err).NotTo(HaveOccurred(), "Webhook endpoints should exist") @@ -256,7 +256,7 @@ var _ = Describe("Manager", Ordered, func() { By("verifying the mutating webhook server is ready") verifyMutatingWebhookReady := func(g Gomega) { cmd := exec.Command("kubectl", "get", "mutatingwebhookconfigurations.admissionregistration.k8s.io", - "cluster-api-provider-stackit-mutating-webhook-configuration", + "capstk-mutating-webhook-configuration", "-o", "jsonpath={.webhooks[0].clientConfig.caBundle}") output, err := utils.Run(cmd) g.Expect(err).NotTo(HaveOccurred(), "MutatingWebhookConfiguration should exist") @@ -267,7 +267,7 @@ var _ = Describe("Manager", Ordered, func() { By("verifying the validating webhook server is ready") verifyValidatingWebhookReady := func(g Gomega) { cmd := exec.Command("kubectl", "get", "validatingwebhookconfigurations.admissionregistration.k8s.io", - "cluster-api-provider-stackit-validating-webhook-configuration", + "capstk-validating-webhook-configuration", "-o", "jsonpath={.webhooks[0].clientConfig.caBundle}") output, err := utils.Run(cmd) g.Expect(err).NotTo(HaveOccurred(), "ValidatingWebhookConfiguration should exist") @@ -349,7 +349,7 @@ var _ = Describe("Manager", Ordered, func() { verifyCAInjection := func(g Gomega) { cmd := exec.Command("kubectl", "get", "mutatingwebhookconfigurations.admissionregistration.k8s.io", - "cluster-api-provider-stackit-mutating-webhook-configuration", + "capstk-mutating-webhook-configuration", "-o", "go-template={{ range .webhooks }}{{ .clientConfig.caBundle }}{{ end }}") mwhOutput, err := utils.Run(cmd) g.Expect(err).NotTo(HaveOccurred()) @@ -363,7 +363,7 @@ var _ = Describe("Manager", Ordered, func() { verifyCAInjection := func(g Gomega) { cmd := exec.Command("kubectl", "get", "validatingwebhookconfigurations.admissionregistration.k8s.io", - "cluster-api-provider-stackit-validating-webhook-configuration", + "capstk-validating-webhook-configuration", "-o", "go-template={{ range .webhooks }}{{ .clientConfig.caBundle }}{{ end }}") vwhOutput, err := utils.Run(cmd) g.Expect(err).NotTo(HaveOccurred())