Skip to content

Commit 07f6abf

Browse files
committed
addressing feedback
1 parent fd00167 commit 07f6abf

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

Makefile

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,7 @@ manifests: controller-gen kustomize ## Generate RBAC objects.
151151
$(CONTROLLER_GEN) rbac:roleName=manager-role webhook paths="./..."
152152
$(SED) -i -E "s|(- )\${MCAD_REPO}.*|\1\${MCAD_CRD}|" config/crd/mcad/kustomization.yaml
153153
$(KUSTOMIZE) build config/crd/mcad > config/crd/mcad.yaml
154+
git restore config/*
154155

155156
.PHONY: fmt
156157
fmt: ## Run go fmt against code.
@@ -194,19 +195,16 @@ endif
194195

195196
.PHONY: install
196197
install: manifests kustomize ## Install CRDs into the K8s cluster specified in ~/.kube/config.
197-
$(SED) -i -E "s|(- )\${MCAD_REPO}.*|\1\${MCAD_CRD}|" config/crd/mcad/kustomization.yaml
198198
$(KUSTOMIZE) build config/crd | kubectl apply -f -
199199
git restore config/*
200200

201201
.PHONY: uninstall
202202
uninstall: 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.
203-
$(SED) -i -E "s|(- )\${MCAD_REPO}.*|\1\${MCAD_CRD}|" config/crd/mcad/kustomization.yaml
204203
$(KUSTOMIZE) build config/crd | kubectl delete --ignore-not-found=$(ignore-not-found) -f -
205204
git restore config/*
206205

207206
.PHONY: deploy
208207
deploy: manifests kustomize ## Deploy controller to the K8s cluster specified in ~/.kube/config.
209-
$(SED) -i -E "s|(- )\${MCAD_REPO}.*|\1\${MCAD_CRD}|" config/crd/mcad/kustomization.yaml
210208
cd config/manager && $(KUSTOMIZE) edit set image controller=${IMG}
211209
$(KUSTOMIZE) build config/${ENV} | kubectl apply -f -
212210
git restore config/*
@@ -286,7 +284,6 @@ validate-bundle: install-operator-sdk
286284
.PHONY: bundle
287285
bundle: defaults manifests kustomize install-operator-sdk ## Generate bundle manifests and metadata, then validate generated files.
288286
$(OPERATOR_SDK) generate kustomize manifests -q
289-
$(SED) -i -E "s|(- )\${MCAD_REPO}.*|\1\${MCAD_CRD}|" config/crd/mcad/kustomization.yaml
290287
cd config/manager && $(KUSTOMIZE) edit set image controller=$(IMG)
291288
cd config/manifests && $(KUSTOMIZE) edit add patch --patch '[{"op":"add", "path":"/metadata/annotations/containerImage", "value": "$(IMG)" }]' --kind ClusterServiceVersion
292289
cd config/manifests && $(KUSTOMIZE) edit add patch --patch '[{"op":"add", "path":"/spec/replaces", "value": "codeflare-operator.$(PREVIOUS_VERSION)" }]' --kind ClusterServiceVersion

config/crd/kustomization.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# This kustomization.yaml is not intended to be run by itself,
22
# since it depends on service name and namespace that are out of this kustomize package.
33
# It should be run by config/default
4-
#resources:
4+
resources:
5+
- mcad.yaml
56

67
#+kubebuilder:scaffold:crdkustomizeresource

0 commit comments

Comments
 (0)