-
Notifications
You must be signed in to change notification settings - Fork 5
/
Makefile
73 lines (53 loc) · 1.79 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
SHELL := bash
DOCKER_TAG ?= latest
# Don't delete intermediary files we touch under .make,
# which are markers for things we have done.
# https://stackoverflow.com/questions/5426934/why-this-makefile-removes-my-goal
.SECONDARY:
bootstrap: .make/bootstrap
# Just alias for bootstrap
setup: .make/bootstrap
docker-build-all: \
docker-build/explorer \
docker-build/build-node-proxy \
docker-build/event-web-server \
docker-build/event-handler
docker-build/explorer: .make/docker-build/explorer
docker-build/build-node-proxy: .make/docker-build/build-node-proxy
docker-build/event-web-server: .make/docker-build/event-web-server
docker-build/event-handler: .make/docker-build/event-handler
build-explorer: .make/npm/build-explorer
build-event-store: .make/npm/build-event-store
build-all: \
build-explorer
test:
yarn test
cd packages/event_store && npm test && cd -
# install all package
.make/bootstrap:
yarn bootstrap
.make/npm/build-explorer: .make/bootstrap
# CI=false so on Drone it won't fail on warnings (currently about href).
yarn run build
mkdir -p $(dir $@) && touch $@
.make/docker-build/explorer: build-explorer
docker build -t make/clarity/web-app .
mkdir -p $(dir $@) && touch $@
.make/docker-build/build-node-proxy:
docker build -t make/clarity/node-proxy .
mkdir -p $(dir $@) && touch $@
.make/docker-build/event-web-server:
cd packages/event_store && \
docker build -t make/clarity/event-store-api -f Dockerfile.api .
mkdir -p $(dir $@) && touch $@
.make/docker-build/event-handler:
cd packages/event_store && \
docker build -t make/clarity/event-store-handler -f Dockerfile.handler .
mkdir -p $(dir $@) && touch $@
clean:
lerna clean -y || true
rm -rf node_modules
rm -rf packages/event_store/node_modules
rm -rf packages/server/dist
rm -rf packages/ui/build
rm -rf .make