forked from medik8s/node-remediation-console
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
31 lines (25 loc) · 774 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# SHELL defines bash so all the inline scripts here will work as expected.
SHELL := /bin/bash
DEFAULT_VERSION := 0.0.1
VERSION ?= $(DEFAULT_VERSION)
export VERSION
# Override this when building images for dev only!
IMAGE_REGISTRY ?= quay.io/medik8s
# For the default version, use 'latest' image tags.
# Otherwise version prefixed with 'v'
ifeq ($(VERSION), $(DEFAULT_VERSION))
IMAGE_TAG = latest
else
IMAGE_TAG = v$(VERSION)
endif
export IMAGE_TAG
# Image pullspec to use for all building/pushing image targets
IMG ?= $(IMAGE_REGISTRY)/node-remediation-console:$(IMAGE_TAG)
# Build the docker image
.PHONY: docker-build
docker-build:
podman build --build-arg VERSION=$(VERSION) -t ${IMG} .
# Push the docker image
.PHONY: docker-push
docker-push:
podman push ${IMG}