updated docker compose
This commit is contained in:
@@ -2,7 +2,6 @@ version: '3.8'
|
|||||||
|
|
||||||
services:
|
services:
|
||||||
web:
|
web:
|
||||||
|
|
||||||
image: digi-server:latest
|
image: digi-server:latest
|
||||||
ports:
|
ports:
|
||||||
- "80:5000"
|
- "80:5000"
|
||||||
@@ -14,9 +13,10 @@ services:
|
|||||||
- SECRET_KEY=Ma_Duc_Dupa_Merele_Lui_Ana
|
- SECRET_KEY=Ma_Duc_Dupa_Merele_Lui_Ana
|
||||||
volumes:
|
volumes:
|
||||||
- .:/app
|
- .:/app
|
||||||
- /home/pi/Desktop/digi-server/db:/app/instance
|
- /home/pi/Desktop/digi-server/db:/app/instance # Persistent database storage
|
||||||
- /home/pi/Desktop/digi-server/static:/app/static/uploads
|
- /home/pi/Desktop/digi-server/static:/app/static/uploads # Persistent static files
|
||||||
# when setting allready exist and data are setted and is performed an update use second line of command
|
# Use this command for first-time setup
|
||||||
command: sh -c "python clear_db.py && python init_db.py && gunicorn -w 4 -b 0.0.0.0:5000 app:app"
|
command: sh -c "python init_db.py && gunicorn -w 4 -b 0.0.0.0:5000 app:app"
|
||||||
#command: sh -c "python init_db.py && gunicorn -w 4 -b 0.0.0.0:5000 app:app"docker
|
# Use this command for subsequent runs to avoid clearing the database
|
||||||
|
# command: gunicorn -w 4 -b 0.0.0.0:5000 app:app
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
|||||||
Reference in New Issue
Block a user