On 11/07, Kevin Heatwole wrote:
> I'm using the latest Alpha Channel release running in an OpenStack VM. I
> run a dozen or so Docker containers per VM with the --restart=always
> option. I've noticed that whenever CoreOS reboots (maybe because of
> updating to a new CoreOS release), the containers on the host do not
> restart, until I ssh in and do a 'docker ps'. The 'docker ps' waits a few
> seconds and then shows all containers as running (up less than a few
> seconds).
Docker doesn't run by default on CoreOS Linux, but is socket-activated.
This is why running `docker ps` starts up all of your containers. If you
want it to run automatically, you just need to enable it:
systemctl enable docker.service
You can also use Ignition to set this up when you provision the VM:
{
"ignition": { "version": "2.0.0" },
"systemd": {
"units": [{
"name": "docker.service",
"enable": "true"
}]
}
}
I hope that helps.
-Alex