I'm running a container app_container built, exposing port 8000 and with its entry point being ENTRYPOINT ["/usr/local/bin/gunicorn", "web_interface:app", "-w 4", "-t 90", "--log-level=info", "-b 127.0.0.1:8000", "--reload"].
My container stops if I try and run the app locally but if I run it with docker run --link postgres_db_container --name foo app_container, the gunicorn command runs to the app.
Locally the container stops here:
[2017-06-19 16:01:16 +0000] [1] [INFO] Starting gunicorn 19.7.1
[2017-06-19 16:01:16 +0000] [1] [INFO] Listening at: http://127.0.0.1:8000
[2017-06-19 16:01:16 +0000] [1] [INFO] Using worker: sync
[2017-06-19 16:01:16 +0000] [8] [INFO] Booting worker with pid: 8
[2017-06-19 16:01:16 +0000] [10] [INFO] Booting worker with pid: 10
[2017-06-19 16:01:16 +0000] [11] [INFO] Booting worker with pid: 11
[2017-06-19 16:01:16 +0000] [13] [INFO] Booting worker with pid: 13
If I interrupt the process it shows a test print message
^C[2017-06-19 16:09:27 +0000] [1] [INFO] Handling signal: int
[2017-06-19 16:09:27 +0000] [10] [INFO] Worker exiting (pid: 10)
[2017-06-19 16:09:27 +0000] [11] [INFO] Worker exiting (pid: 11)
[2017-06-19 16:09:27 +0000] [8] [INFO] Worker exiting (pid: 8)
---- Generate Mapping ----
---- Preparing Databases ----
I think Gunicorn is stuck on some process.
Am I doing anything wrong here? There isn't even any error for me to troubleshoot them.