@@ -45,7 +45,7 @@ help: ## Display this help.
4545
4646.PHONY : manifests
4747manifests : controller-gen # # Generate WebhookConfiguration, ClusterRole and CustomResourceDefinition objects.
48- $(CONTROLLER_GEN ) rbac:roleName=compute crd:generateEmbeddedObjectMeta=true webhook paths=" ./..." output:crd:artifacts:config=config/crd/bases output:rbac:artifacts:config=config/controller_rbac
48+ $(CONTROLLER_GEN ) rbac:roleName=compute crd:generateEmbeddedObjectMeta=true webhook paths=" ./..." output:crd:artifacts:config=config/base/ crd/bases output:rbac:artifacts:config=config/components/ controller_rbac output:webhook:artifacts:config=config/base/webhook
4949
5050.PHONY : generate
5151generate : controller-gen defaulter-gen
@@ -97,7 +97,7 @@ build: manifests generate fmt vet ## Build manager binary.
9797
9898.PHONY : run
9999run : manifests generate fmt vet # # Run a controller from your host.
100- go run ./cmd/main.go -health-probe-bind-address 0 --server-config ./config/dev/config.yaml
100+ go run ./cmd/main.go -health-probe-bind-address 0 --server-config ./config/overlays/ dev/config.yaml
101101
102102# If you wish to build the manager image targeting other platforms you can use the --platform flag.
103103# (i.e. docker build --platform linux/arm64). However, you must enable docker buildKit for it.
@@ -130,8 +130,8 @@ docker-buildx: ## Build and push docker image for the manager for cross-platform
130130.PHONY : build-installer
131131build-installer : manifests generate kustomize # # Generate a consolidated YAML with CRDs and deployment.
132132 mkdir -p dist
133- cd config/manager && $(KUSTOMIZE ) edit set image controller=${IMG}
134- $(KUSTOMIZE ) build config/default > dist/install.yaml
133+ cd config/base/ manager && $(KUSTOMIZE ) edit set image controller=${IMG}
134+ $(KUSTOMIZE ) build config/overlays/single-cluster > dist/install.yaml
135135
136136# #@ Deployment
137137
@@ -141,20 +141,20 @@ endif
141141
142142.PHONY : install
143143install : manifests kustomize # # Install CRDs into the K8s cluster specified in ~/.kube/config.
144- $(KUSTOMIZE ) build config/dev | $(KUBECTL ) apply -f -
144+ $(KUSTOMIZE ) build config/overlays/ dev | $(KUBECTL ) apply -f -
145145
146146.PHONY : uninstall
147147uninstall : manifests kustomize # # Uninstall CRDs from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion.
148- $(KUSTOMIZE ) build config/crd | $(KUBECTL ) delete --ignore-not-found=$(ignore-not-found ) -f -
148+ $(KUSTOMIZE ) build config/base/ crd | $(KUBECTL ) delete --ignore-not-found=$(ignore-not-found ) -f -
149149
150150.PHONY : deploy
151151deploy : manifests kustomize # # Deploy controller to the K8s cluster specified in ~/.kube/config.
152- cd config/manager && $(KUSTOMIZE ) edit set image controller=${IMG}
153- $(KUSTOMIZE ) build config/default | $(KUBECTL ) apply -f -
152+ cd config/base/ manager && $(KUSTOMIZE ) edit set image controller=${IMG}
153+ $(KUSTOMIZE ) build config/overlays/single-cluster | $(KUBECTL ) apply -f -
154154
155155.PHONY : undeploy
156156undeploy : kustomize # # Undeploy controller from the K8s cluster specified in ~/.kube/config. Call with ignore-not-found=true to ignore resource not found errors during deletion.
157- $(KUSTOMIZE ) build config/default | $(KUBECTL ) delete --ignore-not-found=$(ignore-not-found ) -f -
157+ $(KUSTOMIZE ) build config/overlays/single-cluster | $(KUBECTL ) delete --ignore-not-found=$(ignore-not-found ) -f -
158158
159159# #@ Dependencies
160160
@@ -232,7 +232,7 @@ api-docs: crdoc kustomize
232232 @{ \
233233 set -e ; \
234234 TMP_MANIFEST_DIR=$$(mktemp -d ) ; \
235- cp -r config/crd/* $$ TMP_MANIFEST_DIR; \
235+ cp -r config/base/ crd/* $$ TMP_MANIFEST_DIR; \
236236 $(MAKE ) CRD_OPTIONS=$(CRD_OPTIONS ) ,maxDescLen=1200 MANIFEST_DIR=$$ TMP_MANIFEST_DIR/bases manifests ; \
237237 TMP_DIR=$$(mktemp -d ) ; \
238238 $(KUSTOMIZE ) build $$ TMP_MANIFEST_DIR -o $$ TMP_DIR ; \
0 commit comments