-
Notifications
You must be signed in to change notification settings - Fork 7
/
Makefile
53 lines (42 loc) · 1.27 KB
/
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
## Main project Makefile
#
# @author Richard Marston <[email protected]>
# @author Steffen Vogel <[email protected]>
# @copyright 2017, Institute for Automation of Complex Power Systems, EONERC
#
# Pintura
#
# SPDX-License-Identifier: MPL-2.0
#
###################################################################################
DOCKER_IMAGE=sogno/pintura
DOCKER_OPTS?=--rm
TEMPLATE_DIR=generated
ATTRIBUTE_DIR=$(TEMPLATE_DIR)/attributes
GIT_COMMIT=$(shell git log -1 --format=%h)
all: docker
libcimmenu:
docker build -f Dockerfile.menu -t cimmenu .
dev: cimsvg cimmenu
docker build \
--file Dockerfile.dev \
--tag $(DOCKER_IMAGE) \
--iidfile $@ \
--build-arg GIT_COMMIT=git[${GIT_COMMIT}] \
.
docker: cimsvg cimmenu
docker build \
--no-cache \
--tag $(DOCKER_IMAGE) \
--iidfile $@ \
--build-arg GIT_COMMIT=git[${GIT_COMMIT}] \
.
start: stop
docker run $(DOCKER_OPTS) --detach --publish 8082:80 --name=pintura $(DOCKER_IMAGE):latest
echo "Access Pintura at http://localhost:8082"
start-cimmenu:
docker run $(DOCKER_OPTS) --detach --publish 8084:80 --name=libcimmenu cimmenu:latest
echo "Access Pintura at http://localhost:8082"
stop:
$(shell echo ./stop_docker.sh)
.PHONY: all dev docker libcimmenu start stop start-cimmenu