I'm using docker
and docker-compose
.
Inside docker-compose.yml
I have command that starts django server:
command: ["./run/web.sh"]
In json format command should run in exec mode. Inside web.sh
:
#!/usr/bin/env bash
exec python manage.py runserver
When I tried to stop service with docker-compose stop
it waited 10 seconds (default timeout) and then just kill service. In logs I've found project_web_1 exited with code 137
.
How to stop django runserver gracefully with docker stop
?