forked from oricou/delta
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
37 lines (30 loc) · 1001 Bytes
/
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
.PHONY: docker
debug:
sed -i -e 's/^@profile/#@profile/' delta.py
sed -i -e 's/profile = True/profile = False/' delta.py
poetry run python delta.py
run:
sed -i -e 's/^@profile/#@profile/' delta.py
sed -i -e 's/profile = True/profile = False/' delta.py
#poetry run gunicorn --workers 1 -b 0.0.0.0:8000 delta:server
poetry run gunicorn --timeout 360 --workers 1 -b 0.0.0.0:8000 delta:server
profile:
sed -i -e 's/^#@profile/@profile/' delta.py
sed -i -e 's/profile = False/profile = True/' delta.py
poetry run kernprof -l delta.py
poetry run python -m line_profiler delta.py.lprof
docker:
mv ps_ap_chessgames/data /tmp
tar czvf apps.tgz delta.py */
mv /tmp/data ps_ap_chessgames/
docker build -t oricou/delta .
docker_no_cache:
mv ps_ap_chessgames/data /tmp
tar czvf apps.tgz delta.py */
mv /tmp/data ps_ap_chessgames/
docker build --no-cache -t oricou/delta .
install:
docker login
docker push oricou/delta
docker_run:
docker run -dit --name delta -p8000:8000 oricou/delta