forked from ansibleplaybookbundle/apb-base
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
32 lines (27 loc) · 867 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
32
CONTEXT = ansibleplaybookbundle
VERSION = v2.3
IMAGE_NAME = apb-base
TARGET = centos7
REGISTRY = docker-registry.default.svc.cluster.local
OC_USER = developer
OC_PASS = developer
# Allow user to pass in OS build options
ifeq ($(TARGET),rhel7)
DFILE := Dockerfile-latest.${TARGET}
else
DFILE := Dockerfile-latest
endif
all: build
build:
docker build --pull -t ${CONTEXT}/${IMAGE_NAME}:${TARGET}-${VERSION} -t ${CONTEXT}/${IMAGE_NAME} -f ${DFILE} .
@if docker images ${CONTEXT}/${IMAGE_NAME}:${TARGET}-${VERSION}; then touch build; fi
lint:
dockerfile_lint -f Dockerfile
# dockerfile_lint -f Dockerfile.rhel7
openshift-test:
${MAKE} -C ../hello-world-apb TARGET=${TARGET}
${MAKE} openshift-test -C ../hello-world-apb TARGET=${TARGET}
${MAKE} -C ../jenkins-apb TARGET=${TARGET}
${MAKE} openshift-test -C ../jenkins-apb TARGET=${TARGET}
clean:
rm -f build