mirror of
https://github.com/rancher/rke.git
synced 2025-08-15 13:34:36 +00:00
Change Ignore to enforce docker version
This commit is contained in:
parent
6cebe31ed3
commit
203bd005e3
@ -19,7 +19,7 @@ network:
|
|||||||
flannel_cni_image: quay.io/coreos/flannel-cni:v0.2.0
|
flannel_cni_image: quay.io/coreos/flannel-cni:v0.2.0
|
||||||
|
|
||||||
ssh_key_path: ~/.ssh/test
|
ssh_key_path: ~/.ssh/test
|
||||||
ignore_docker_version: false
|
enforce_docker_version: false
|
||||||
# Kubernetes authorization mode; currently only `rbac` is supported and enabled by default.
|
# Kubernetes authorization mode; currently only `rbac` is supported and enabled by default.
|
||||||
# Use `mode: none` to disable authorization
|
# Use `mode: none` to disable authorization
|
||||||
authorization:
|
authorization:
|
||||||
|
@ -38,7 +38,7 @@ func (c *Cluster) InvertIndexHosts() error {
|
|||||||
RKEConfigNode: host,
|
RKEConfigNode: host,
|
||||||
}
|
}
|
||||||
|
|
||||||
newHost.IgnoreDockerVersion = c.IgnoreDockerVersion
|
newHost.EnforceDockerVersion = c.EnforceDockerVersion
|
||||||
|
|
||||||
for _, role := range host.Role {
|
for _, role := range host.Role {
|
||||||
logrus.Debugf("Host: " + host.Address + " has role: " + role)
|
logrus.Debugf("Host: " + host.Address + " has role: " + role)
|
||||||
|
@ -19,7 +19,7 @@ type Host struct {
|
|||||||
HealthcheckPort int
|
HealthcheckPort int
|
||||||
IsControl bool
|
IsControl bool
|
||||||
IsWorker bool
|
IsWorker bool
|
||||||
IgnoreDockerVersion bool
|
EnforceDockerVersion bool
|
||||||
}
|
}
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
@ -47,7 +47,7 @@ func (h *Host) TunnelUp(dialerFactory DialerFactory) error {
|
|||||||
return fmt.Errorf("Error while determining supported Docker version [%s]: %v", info.ServerVersion, err)
|
return fmt.Errorf("Error while determining supported Docker version [%s]: %v", info.ServerVersion, err)
|
||||||
}
|
}
|
||||||
|
|
||||||
if !isvalid && !h.IgnoreDockerVersion {
|
if !isvalid && h.EnforceDockerVersion {
|
||||||
return fmt.Errorf("Unsupported Docker version found [%s], supported versions are %v", info.ServerVersion, docker.K8sDockerVersions[K8sVersion])
|
return fmt.Errorf("Unsupported Docker version found [%s], supported versions are %v", info.ServerVersion, docker.K8sDockerVersions[K8sVersion])
|
||||||
} else if !isvalid {
|
} else if !isvalid {
|
||||||
logrus.Warnf("Unsupported Docker version found [%s], supported versions are %v", info.ServerVersion, docker.K8sDockerVersions[K8sVersion])
|
logrus.Warnf("Unsupported Docker version found [%s], supported versions are %v", info.ServerVersion, docker.K8sDockerVersions[K8sVersion])
|
||||||
|
Loading…
Reference in New Issue
Block a user