The recent changes to containerd in docker 17.12 broke railcar in two
ways:
1) The containerd-shim blocks waiting to receive the console file
descriptor in create. Railcar was previously not creating the console
until start was called.
2) The containerd-shim sets PR_SET_CHILD_SUBREAPER to 1. Railcar was
using a double fork and exiting the parent during start to force the
child to reparent to rc-init. Unfortunately, this setting causes it to
reparent to containerd-shim instead, breaking the exit detection of the
init process.
This was fixed by switching to a technique that is similar to docker.
The console file descriptor is passed back during create. Start simply
calls does the hooks and then triggers rc-init to exec the configured
process. The old behavior can be recovered by passing --no-trigger to
railcar create.
This also includes some other minor fixes and cleanups to various commands.
The recent changes to containerd in docker 17.12 broke railcar in two ways:
1) The containerd-shim blocks waiting to receive the console file descriptor in create. Railcar was previously not creating the console until start was called.
2) The containerd-shim sets PR_SET_CHILD_SUBREAPER to 1. Railcar was using a double fork and exiting the parent during start to force the child to reparent to rc-init. Unfortunately, this setting causes it to reparent to containerd-shim instead, breaking the exit detection of the init process.
This was fixed by switching to a technique that is similar to docker. The console file descriptor is passed back during create. Start simply calls does the hooks and then triggers rc-init to exec the configured process. The old behavior can be recovered by passing --no-trigger to railcar create.
This also includes some other minor fixes and cleanups to various commands.