-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
40 lines (26 loc) · 705 Bytes
/
Makefile
File metadata and controls
40 lines (26 loc) · 705 Bytes
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
-include env_make
ALPINE_VER ?= 3.6
TAG ?= $(ALPINE_VER)
REPO = wodby/abuild
NAME = abuild-$(ALPINE_VER)
.PHONY: build test push shell run start stop logs clean release
default: build
build:
docker build -t $(REPO):$(TAG) --build-arg ALPINE_VER=$(ALPINE_VER) ./
test:
echo "OK"
push:
docker push $(REPO):$(TAG)
shell:
docker run --rm --name $(NAME) -i -t $(PORTS) $(VOLUMES) $(ENV) $(REPO):$(TAG) /bin/bash
run:
docker run --rm --name $(NAME) -e DEBUG=1 $(PORTS) $(VOLUMES) $(ENV) $(REPO):$(TAG) $(CMD)
start:
docker run -d --name $(NAME) $(PORTS) $(VOLUMES) $(ENV) $(REPO):$(TAG)
stop:
docker stop $(NAME)
logs:
docker logs $(NAME)
clean:
-docker rm -f $(NAME)
release: build push