-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathMakefile
More file actions
51 lines (38 loc) · 988 Bytes
/
Makefile
File metadata and controls
51 lines (38 loc) · 988 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
41
42
43
44
45
46
47
48
49
50
51
GIT_SHORTHASH := $(shell git rev-parse --short HEAD)
DOCKER_IMAGE_TAG := $(GIT_SHORTHASH)
VIRTUAL_ENV ?= ./.venv
export VIRTUAL_ENV
export DOCKER_IMAGE_TAG
docker-build: \
docker-build-site \
docker-build-vanity \
docker-build-playground-executor \
docker-build-tour
docker-push: \
docker-push-site \
docker-push-vanity \
docker-push-playground-executor \
docker-push-tour
docker-build-%:
docker build -t "upper/${*}:${DOCKER_IMAGE_TAG}" -f "${*}/Dockerfile" "${*}/"
docker-push-%: docker-build-%
docker tag "upper/${*}:${DOCKER_IMAGE_TAG}" "upper/${*}:latest"
docker push "upper/${*}:${DOCKER_IMAGE_TAG}" && \
docker push "upper/${*}:latest"
deploy-%:
ansible-playbook \
-i "./inventory/${*}.yml" \
-v playbook.yml
deploy: \
deploy-local
yamlfmt:
find . -name \*.yml | grep -v node_modules | xargs yamlfmt
run:
(cd site && \
yarn start --host 0.0.0.0)
run-tour:
cd tour && \
go run cmd/tour/main.go
build:
(cd site && \
yarn build)