Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added all in one makefile rule to deploy bundle images #461

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,13 @@ deploy-with-olm: deploy-olm load-on-kind build-and-push-bundle-images ## deploys
$(KUSTOMIZE) build config/olm-install | kubectl apply -f -
VERSION=$(CSV_VERSION) NAMESPACE=$(NAMESPACE) hack/wait-for-csv.sh

deploy-olm-real: export OPERATOR_SDK=operator-sdk
deploy-olm-real: deploy-olm build-and-push-bundle-images ## deploys the operator via OLM on a real cluster
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should remove the deploy-olm dependency?

Also, I wonder if we can refactor this a bit to avoid duplications with deploy-with-olm

sed -i 's|image:.*|image: $(BUNDLE_INDEX_IMG)|' config/olm-install/install-resources.yaml
sed -i 's#mymetallb#$(NAMESPACE)#g' config/olm-install/install-resources.yaml
$(KUSTOMIZE) build config/olm-install | kubectl apply -f -
VERSION=$(CSV_VERSION) NAMESPACE=$(NAMESPACE) hack/wait-for-csv.sh

bundle-index-build: opm ## Build the bundle index image.
$(OPM) index add --bundles $(BUNDLE_IMG) --tag $(BUNDLE_INDEX_IMG) -c docker -i quay.io/operator-framework/opm:$(OPM_VERSION)

Expand Down
10 changes: 5 additions & 5 deletions config/manager/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
resources:
- manager.yaml
- manager.yaml
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this shouldn't be part of this commit

apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
patchesStrategicMerge:
- env.yaml
- env.yaml
images:
- name: controller
newName: quay.io/metallb/metallb-operator
newTag: main
- name: controller
newName: quay.io/metallb/metallb-operator
newTag: dev