19 lines
No EOL
654 B
Makefile
19 lines
No EOL
654 B
Makefile
default: start
|
|
dev: start
|
|
# Use PORT environment variable if set, otherwise default to 8080
|
|
PORT ?= 8080
|
|
# Log file for daemonized uWSGI
|
|
LOGFILE ?= uwsgi.log
|
|
|
|
start:
|
|
python3 -m venv venv
|
|
. venv/bin/activate && pip install -r requirements.txt && uwsgi --http :$(PORT) --wsgi-file backend.py --callable app
|
|
|
|
websocket:
|
|
python3 -m venv venv
|
|
. venv/bin/activate && pip install -r requirements.txt && pip install websockets && uwsgi --ini uwsgi.ini
|
|
|
|
# Version en arrière-plan (démon)
|
|
websocket-daemon:
|
|
python3 -m venv venv
|
|
. venv/bin/activate && pip install -r requirements.txt && pip install websockets && uwsgi --ini uwsgi.ini --daemonize $(LOGFILE)
|