valum-framework/valum

Cannot send SIGTERM to service in Docker container

arteymix opened this issue · 3 comments

We have right to the following error when sending a SIGTERM to a running docker container.

GLib-WARNING **: poll(2) failed due to: Operation not permitted.

I investigated this and it seems we can still send a SIGTERM via docker stop, it just doesn't play well via the pseudo-TTY.

This can wait for a patch release.

^C works fine when my Dockerfile contains:

ENTRYPOINT /app/bin/app --any --port 3003

but it doesn't do anything when my Dockerfile contains:

ENTRYPOINT ["/app/bin/app", "--any", "--port", "3003"]

The difference here is that your option implies using a shell for running the command. Ideally VSGI should handle SIGTERM properly.