Use CMD exec in Dockerfile
Without exec the `postgrest` process is not run with PID 1 (it is a child process of the shell that starts it). This means signals send to the docker (like `docker stop` or ^C) will not be handled correctly. However, Linux treats PID 1 as special and sets the SIGTERM handler to ignore by default. It is also necessary to install a SIGTERM handler. This commit adds `exec` to resolve this problem, as per the recommendation in the Dockerfile documentation: https://docs.docker.com/engine/reference/builder/#shell-form-entrypoint-example
This commit is contained in:
+1
-1
@@ -6,7 +6,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
|
||||
## Unreleased
|
||||
|
||||
### Fixed
|
||||
- Terminate gracefully on SIGTERM - @recmo
|
||||
* Terminate gracefully on SIGTERM (for use in Docker) - @recmo
|
||||
|
||||
## [0.3.1.0] - 2016-02-28
|
||||
|
||||
|
||||
Reference in New Issue
Block a user