Closed zcqian closed 3 years ago
I have tested locally that every image should build and run fine. Someone else please review and test. After that, please squash commits and merge.
Add a note about the use of sleep infinity
:
If this becomes an issue, e.g. the process stops at some point, an alternative could be this:
python -c 'while 1: import ctypes; ctypes.CDLL(None).pause()'
Resolves Issue #63
In addition to updated Ubuntu version, the following changes has been made:
systemctl
link in/usr/sbin/systemctl
to/usr/bin/true
. This was to prevent MongoDB post-install scripts to call thesystemctl
command. This need has been negated because OpenSSH server and software-properties-common are removed, hence systemd is no longer pulled into the image. Usually people create dummy packages to address issues like this, but because systemd usually depends on exact versions of a package, a dummy package that "provides" systemd does not work in this case. I'm leaving the notes here because after the commits are squashed, the workaround will not be in the git commit history.sshd
) was previously running in the foreground indocker-entrypoint.sh
to prevent this PID 1 process from exiting. Now that it has been removed,sleep infinity
is invoked to prevent the script from exiting. Despite the argument "infinity" it only sleeps for a finite time, but it should be long enough to run for a few days at least (depends on the maximum value supported bytime_t
.