-
Notifications
You must be signed in to change notification settings - Fork 0
/
includes.mk
40 lines (34 loc) · 923 Bytes
/
includes.mk
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
33
34
35
36
37
38
39
40
ifndef DEIS_NUM_INSTANCES
DEIS_NUM_INSTANCES = 3
endif
define echo_cyan
@echo "\033[0;36m$(subst ",,$(1))\033[0m"
endef
define echo_yellow
@echo "\033[0;33m$(subst ",,$(1))\033[0m"
endef
SELF_DIR := $(dir $(lastword $(MAKEFILE_LIST)))
DOCKER_HOST = $(shell echo $$DOCKER_HOST)
REGISTRY = $(shell echo $$DEV_REGISTRY)
GIT_SHA = $(shell git rev-parse --short HEAD)
ifndef BUILD_TAG
BUILD_TAG = git-$(GIT_SHA)
endif
ifndef S3_BUCKET
S3_BUCKET = deis-updates
endif
IMAGE_PREFIX := deis/
check-docker:
@if [ -z $$(which docker) ]; then \
echo "Missing \`docker\` client which is required for development"; \
exit 2; \
fi
check-registry:
@if [ -z "$$DEV_REGISTRY" ]; then \
echo "DEV_REGISTRY is not exported, try: make dev-registry"; \
exit 2; \
fi
check-deisctl:
@if [ -z $$(which deisctl) ]; then \
echo "Missing \`deisctl\` utility, please install from https://github.com/deis/deis"; \
fi