forked from cesium-ml/cesium_web
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
69 lines (47 loc) · 1.47 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
SHELL = /bin/bash
SUPERVISORD=supervisord
.DEFAULT_GOAL := run
bundle = ./public/build/bundle.js
webpack = ./node_modules/.bin/webpack
dependencies:
@./tools/silent_monitor.py ./tools/install_deps.py requirements.txt
@./tools/silent_monitor.py ./tools/check_js_deps.sh
db_init:
@./tools/silent_monitor.py ./tools/db_create.sh
db_drop:
@PYTHONPATH=. ./tools/silent_monitor.py ./tools/db_drop.py
db_test_data:
@PYTHONPATH=. python ./cesium_app/models.py
$(bundle): webpack.config.js package.json
$(webpack)
bundle: $(bundle)
bundle-watch:
$(webpack) -w
paths:
@mkdir -p log run tmp
@mkdir -p log/sv_child
@mkdir -p ~/.local/cesium/logs
log: paths
./tools/watch_logs.py
run: paths dependencies
$(SUPERVISORD) -c conf/supervisord.conf
debug:
$(SUPERVISORD) -c conf/supervisord_debug.conf
# Attach to terminal of running webserver; useful to, e.g., use pdb
attach:
supervisorctl -c conf/supervisord_common.conf fg app
clean:
rm $(bundle)
test_headless: paths dependencies
PYTHONPATH='.' xvfb-run ./tools/frontend_tests.py
test: paths dependencies
PYTHONPATH='.' ./tools/frontend_tests.py
status:
PYTHONPATH='.' ./tools/supervisor_status.py
docker-images:
# Add --no-cache flag to rebuild from scratch
docker build -t cesium/web . && docker push cesium/web
cd docker/postgres && docker build -t cesium/postgres . && docker push cesium/postgres
# Call this target to see which Javascript dependencies are not up to date
check-js-updates:
./tools/check_js_updates.sh