diff --git a/Makefile b/Makefile index 1a3ec8e..cd395f5 100644 --- a/Makefile +++ b/Makefile @@ -27,6 +27,8 @@ include env.local N_CORES = 5 # insert kres files into database in chunks, for fewer connections KRES_CHUNK_SIZE = 30 + +# Backend parameters found in conf file (see make backend) export .PHONY: python-env fill-database @@ -107,3 +109,8 @@ backend-dev: cd ./src/backend_flask; python3 app.py \ --config-file ./conf_files/dev_conf.yaml \ --dbuser $(DB_USR_USER) --dbpass $(DB_USR_PASS) --dbaddr $(DBADDR) + +backend-prod: + cd ./src/backend_flask; python3 app.py \ + --config-file ./conf_files/prod_conf.yaml \ + --dbuser $(DB_USR_USER) --dbpass $(DB_USR_PASS) --dbaddr $(DBADDR) diff --git a/dockerfiles/python-env/Makefile b/dockerfiles/python-env/Makefile index 339cc75..e9b30d4 100644 --- a/dockerfiles/python-env/Makefile +++ b/dockerfiles/python-env/Makefile @@ -11,6 +11,7 @@ run: - docker rm $(CNNAME) docker run \ -it \ + -v $(HOME):$(HOME) \ -v $(MAKE_ROOT):/project \ -w /project \ --net host \ diff --git a/src/backend_flask/conf_files/prod_conf.yaml b/src/backend_flask/conf_files/prod_conf.yaml new file mode 100644 index 0000000..c5aaa24 --- /dev/null +++ b/src/backend_flask/conf_files/prod_conf.yaml @@ -0,0 +1,6 @@ +--- +debug: True +port: 8084 +host: 0.0.0.0 +logfile: "/var/log/valency_backend.log" +---