all-in-one
all-in-one copied to clipboard
Fix signal handling for mastercontainer
When stopping the mastercontainer, docker / podman send SIGQUIT / SIGTERM to the container. These are not handled today and that's why docker/podman just force kill the containers. The supervisord already knows how to handle these signals, but the signals are intercepted by the bash process and never reach supervisord. This PR fixes that by using bash process replacement, so supervisord becomes the primary process once it runs and can receive signals. With this container stopping becomes graceful and not a force kill.