Skip to content

Commit

Permalink
add manifest file and script for deployment
Browse files Browse the repository at this point in the history
  • Loading branch information
rahulanand16nov committed Jan 10, 2022
1 parent 0b48e82 commit b7b9509
Show file tree
Hide file tree
Showing 2 changed files with 825 additions and 2 deletions.
17 changes: 15 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,25 @@ BUNDLE_DEFAULT_CHANNEL := --default-channel=$(DEFAULT_CHANNEL)
endif
BUNDLE_METADATA_OPTS ?= $(BUNDLE_CHANNELS) $(BUNDLE_DEFAULT_CHANNEL)

# Address of the container registry
REGISTRY = quay.io

# Organization in container resgistry
ORG ?= kuadrant

# IMAGE_TAG_BASE defines the docker.io namespace and part of the image name for remote images.
# This variable is used to construct full image tags for bundle and catalog images.
#
# For example, running 'make bundle-build bundle-push catalog-build catalog-push' will build and push both
# quay.io/kuadrant/limitador-operator-bundle:$VERSION and quay.io/kuadrant/limitador-operator-catalog:$VERSION.
IMAGE_TAG_BASE ?= quay.io/kuadrant/limitador-operator
IMAGE_TAG_BASE ?= $(REGISTRY)/$(ORG)/limitador-operator

# BUNDLE_IMG defines the image:tag used for the bundle.
# You can use it as an arg. (E.g make bundle-build BUNDLE_IMG=<some-registry>/<project-name-bundle>:<tag>)
BUNDLE_IMG ?= $(IMAGE_TAG_BASE)-bundle:v$(VERSION)

# Image URL to use all building/pushing image targets
IMG ?= quay.io/kuadrant/limitador-operator:latest
IMG ?= $(IMAGE_TAG_BASE):latest
# ENVTEST_K8S_VERSION refers to the version of kubebuilder assets to be downloaded by envtest binary.
ENVTEST_K8S_VERSION = 1.22

Expand Down Expand Up @@ -150,6 +156,13 @@ rm -rf $$TMP_DIR ;\
}
endef

DEPLOYMENT_DIR = $(PROJECT_DIR)/config/deploy
.PHONY: deploy-manifest
deploy-manifest:
mkdir -p $(DEPLOYMENT_DIR)
cd $(PROJECT_DIR)/config/manager && $(KUSTOMIZE) edit set image controller=$(IMG) ;\
cd $(PROJECT_DIR) && $(KUSTOMIZE) build config/default >> $(DEPLOYMENT_DIR)/manfiests.yaml

OPERATOR_SDK = $(shell pwd)/bin/operator-sdk
OPERATOR_SDK_VERSION = v1.15.0
operator-sdk: ## Download operator-sdk locally if necessary.
Expand Down
Loading

0 comments on commit b7b9509

Please sign in to comment.