diff --git a/common/docker/client.go b/common/docker/client.go index cc845c28..1a9e2c09 100644 --- a/common/docker/client.go +++ b/common/docker/client.go @@ -98,7 +98,7 @@ func (c *Client) AddObserver(ob ContainerObserver) error { func (c *Client) IsContainerNotRunning(idStr string) bool { container, err := c.InspectContainer(idStr) if err == nil { - return !container.State.Running + return !container.State.Running || container.State.Restarting } if _, notThere := err.(*docker.NoSuchContainer); notThere { return true diff --git a/proxy/proxy.go b/proxy/proxy.go index 30475d1f..a287cc8f 100644 --- a/proxy/proxy.go +++ b/proxy/proxy.go @@ -474,7 +474,7 @@ func (proxy *Proxy) attach(containerID string, orDie bool) error { Log.Infof("Attaching weave router container: %s", container.ID) return callWeaveAttach(container, []string{"attach-router"}) } - if !containerShouldAttach(container) || !(container.State.Running || container.State.Paused) { + if !containerShouldAttach(container) || !container.State.Running { return nil }