Browse Source

Merge pull request #31631 from aaronlehmann/swarm-failure-on-startup

cluster: Proceed with startup if cluster component can't be created
Aaron Lehmann 8 years ago
parent
commit
9b33edfa7e
1 changed files with 2 additions and 8 deletions
  1. 2 8
      daemon/cluster/cluster.go

+ 2 - 8
daemon/cluster/cluster.go

@@ -39,7 +39,6 @@ package cluster
 //
 
 import (
-	"crypto/x509"
 	"fmt"
 	"net"
 	"os"
@@ -171,13 +170,8 @@ func New(config Config) (*Cluster, error) {
 		logrus.Error("swarm component could not be started before timeout was reached")
 	case err := <-nr.Ready():
 		if err != nil {
-			if errors.Cause(err) == errSwarmLocked {
-				return c, nil
-			}
-			if err, ok := errors.Cause(c.nr.err).(x509.CertificateInvalidError); ok && err.Reason == x509.Expired {
-				return c, nil
-			}
-			return nil, errors.Wrap(err, "swarm component could not be started")
+			logrus.WithError(err).Error("swarm component could not be started")
+			return c, nil
 		}
 	}
 	return c, nil