-
Notifications
You must be signed in to change notification settings - Fork 23
/
Makefile
43 lines (35 loc) · 1.03 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
.ONESHELL:
.PHONY: all
all: clean build develop
.PHONY: venv
venv: requirements-dev.txt tox.ini
pip install -r requirements-dev.txt
# install python dependencies
tox -e venv
# install npm dependencies
venv/bin/jlpm install
. venv/bin/activate
.PHONY: build
build: venv
venv/bin/jlpm build
PIP_USER=false venv/bin/pip install -I .
develop:
ipython profile create --ipython-dir=.ipython
echo "c.InteractiveShellApp.extensions.append('sparkmonitor.kernelextension')" >> .ipython/profile_default/ipython_config.py
IPYTHONDIR=.ipython venv/bin/jupyter lab --watch --NotebookApp.allow_origin='*'
.PHONY: clean
clean:
rm -rf venv
rm -rf node_modules
rm -rf .ipython
rm -rf lib
.PHONY: lint
lint: frontend-build
venv/bin/jlpm run eslint
dist: build
rm -rf dist/
venv/bin/python setup.py bdist_wheel
.PHONY: itest
itest: dist
docker build --tag itsjafer/sparkmonitor:itest --build-arg VERSION=$$(venv/bin/python setup.py --version) .
docker run --rm -p 8888:8888 -p 4040:4040 -e JUPYTER_ENABLE_LAB=yes itsjafer/sparkmonitor:itest