# /etc/sysconfig/docker
# Modify these options if you want to change the way the docker daemon runs
OPTIONS="--selinux-enabled \
--log-driver=journald \
--default-ulimit nofile=122880:122880 \
--init-path /usr/libexec/docker/docker-init \
--userland-proxy-path /usr/libexec/docker/docker-proxy \
--live-restore \
"
However, the docker daemon does not pick up those options:
Creating an explicit drop-in to override ExecStart and explicitly set the options works, but I’m surprised the default CoreOS configuration is so broken as to completely ignore /etc/sysconfig/docker. I am not doing anything to modify this behavior in the ignition file.
I looked at my options file again with a more critical eye, and turns out I had a comment with a line continuation character at the end, like this:
# Swarm is not compatible with --live-restore \
OPTIONS="--selinux-enabled \
--log-driver=journald \
--default-ulimit nofile=122880:122880 \
--init-path /usr/libexec/docker/docker-init \
--userland-proxy-path /usr/libexec/docker/docker-proxy \
--live-restore \
"
and it seems that systemd parses this such that the line continuation character at the end of the comment makes OPTIONS part of the comment!
Bash ignores the line continuation character at the end of the comment so this is at the very least surprising behavior, if not a bug in systemd’s parsing of these files.