2
docker run \
    -d \
    -e "SOME_ENV_VAR=someValue" \
    -h some.host.com \
    --link db-thing:db \
    --name someName \
    -p 5555:5555 \
    --restart always \
    -v /someFile:/otherFile:ro \
    -v /someDir/:/otherDir/ \
    web-thing

I'm using docker 1.7.1 on CentOS. I started some containers with --restart always, then rebooted the server. Docker came back up, but none of the containers/images restarted. I thought they might depend on each other, so restarted the db-thing image, but even then the others still didn't restart. What could keep the containers from restarting?

Does this have anything to do with this: How to setup linkage between docker containers so that restarting won't break it?

Community
  • 1
  • 1
GlenPeterson
  • 4,866
  • 5
  • 41
  • 49

1 Answers1

1

I tried again and it worked. Doh! My best guess is that I was developing my docker commands in a file (to check into source control) and I must have forgotten to run the version of the command that had --restart always. Embarrassing!

GlenPeterson
  • 4,866
  • 5
  • 41
  • 49