NebulousLabs / docker-sia

The official docker image for the Sia daemon
https://sia.tech
MIT License
20 stars 1 forks source link

Switch from the shell version to the exec version of ENTRYPOINT. #7

Closed ro-tex closed 4 years ago

ro-tex commented 4 years ago

This PR switches from using the shell version of ENTRYPOINT to the exec version.

The difference between the two versions is that in the shell one the executed command is run within an instance of /bin/sh which holds PID 1. The problem is that when the container is stopped /bin/sh receives the SIGTERM signal but doesn't send it to its children. This prevents siad from performing a graceful shutdown and exposes the user to a risk of data corruption. This chances of data corruption occurring is small since all disk operations performed by siad should be ACID. Nevertheless, nothing should stop us from eliminating it completely.

Closes #6