rancher / vagrant

Vagrant file to stand up a Local Rancher install with 3 nodes
81 stars 56 forks source link

Master VM containers don't survive reboot #30

Closed LLParse closed 6 years ago

LLParse commented 6 years ago

Some of the containers deployed on the master VM aren't restarted when the VM is suspended or stopped.

dnoland1 commented 6 years ago

Specifically haproxy, redis-mirror, and v2-mirror docker containers are not starting after master VM reboot and showing the following errors in the logs:

haproxy container_linux.go:247: starting container process caused "process_linux.go:359: container init caused \"rootfs_linux.go:54: mounting \\\"/vagrant/.vagrant/data/haproxy.cfg\\\" to rootfs \\\"/var/lib/docker/aufs/mnt/d88b9dff830332eda0787a730b2e04d2e5b74193ca75e9af2bfee4e79e069ec6\\\" at \\\"/var/lib/docker/aufs/mnt/d88b9dff830332eda0787a730b2e04d2e5b74193ca75e9af2bfee4e79e069ec6/usr/local/etc/haproxy/haproxy.cfg\\\" caused \\\"not a directory\\\"\""

redis-mirror # Fatal error, can't open config file '/data/redis.conf'

v2-mirror configuration error: open /var/lib/registry/config.yml: no such file or directory

LLParse commented 6 years ago

I would recommend we write the configuration files into the VM somewhere on first boot. It's up to you where to put them, perhaps /etc/vagrant or something.

LLParse commented 6 years ago

Actually, this would solve 1 problem but cause another: cache contents not persisted to the host. That is arguably worse because some people have very slow net links and can't afford to rebuild their entire cache after destroying/recreating an environment (for whatever reason).