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

Makefile: generate default image name based on current user #730

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 10 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,23 @@
# To re-generate a bundle for another specific version without changing the standard setup, you can:
# - use the VERSION as arg of the bundle target (e.g make bundle VERSION=0.0.2)
# - use environment variables to overwrite this value (e.g export VERSION=0.0.2)
IMAGE_OWNER ?= opendatahub
ifneq ($(USER),)
IMAGE_OWNER = $(USER)
else
IMAGE_OWNER = opendatahub
endif
VERSION ?= 2.4.0
# IMAGE_TAG_BASE defines the opendatahub.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
# opendatahub.io/opendatahub-operator-bundle:$VERSION and opendatahub.io/opendatahub-operator-catalog:$VERSION.
IMAGE_TAG_BASE ?= quay.io/$(IMAGE_OWNER)/opendatahub-operator
IMAGE_TAG_BASE = quay.io/$(IMAGE_OWNER)/opendatahub-operator

# keep the name based on IMG which already used from command line
IMG_TAG = latest
# Update IMG to a variable, to keep it consistent across versions for OpenShift CI
IMG ?= REPLACE_IMAGE
IMG = $(IMAGE_TAG_BASE):$(IMG_TAG)
# 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)
Expand Down
Loading