forked from parodos-dev/backstage-parodos
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
26 lines (19 loc) · 842 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
DOCKER ?= docker
ORG=quay.io/parodos-dev/
IMAGE=backstage-parodos
GIT_BRANCH := $(shell git rev-parse --abbrev-ref HEAD | sed s,^main$$,latest,g)
GIT_HASH := $(shell git rev-parse HEAD)
build-image:
./scripts/build-image.sh
$(DOCKER) tag backstage:latest $(ORG)$(IMAGE):$(GIT_BRANCH)
$(DOCKER) tag backstage:latest $(ORG)$(IMAGE):$(GIT_HASH)
build-image-openshift:
$(DOCKER) build -t backstage:latest-openshift -f Dockerfile-openshift .
$(DOCKER) tag backstage:latest-openshift $(ORG)$(IMAGE):$(GIT_BRANCH)-openshift
$(DOCKER) tag backstage:latest-openshift $(ORG)$(IMAGE):$(GIT_HASH)-openshift
push-image:
$(DOCKER) push $(ORG)$(IMAGE):$(GIT_HASH)
$(DOCKER) push $(ORG)$(IMAGE):$(GIT_BRANCH)
push-image-openshift:
$(DOCKER) push $(ORG)$(IMAGE):$(GIT_HASH)-openshift
$(DOCKER) push $(ORG)$(IMAGE):$(GIT_BRANCH)-openshift