Skip to content

Commit

Permalink
Merge pull request #23 from neolit123/1.21-update-docker
Browse files Browse the repository at this point in the history
docker_validator: allow Docker 20.10.*
  • Loading branch information
k8s-ci-robot authored Feb 11, 2021
2 parents ec744eb + 13e0dde commit ef4e32f
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion validators/docker_validator.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ func (d *DockerValidator) Name() string {

const (
dockerConfigPrefix = "DOCKER_"
latestValidatedDockerVersion = "19.03"
latestValidatedDockerVersion = "20.10"
)

// Validate is part of the system.Validator interface.
Expand Down
8 changes: 7 additions & 1 deletion validators/docker_validator_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ func TestValidateDockerInfo(t *testing.T) {
Reporter: DefaultReporter,
}
spec := &DockerSpec{
Version: []string{`1\.13\..*`, `17\.0[3,6,9]\..*`, `18\.0[6,9]\..*`, `19\.03\..*`},
Version: []string{`1\.13\..*`, `17\.0[3,6,9]\..*`, `18\.0[6,9]\..*`, `19\.03\..*`, `20\.10\..*`},
GraphDriver: []string{"driver_1", "driver_2"},
}
for _, test := range []struct {
Expand Down Expand Up @@ -97,6 +97,12 @@ func TestValidateDockerInfo(t *testing.T) {
err: false,
warn: true,
},
{
name: "valid Docker version 20.10.3",
info: dockerInfo{Driver: "driver_2", ServerVersion: "20.10.3"},
err: false,
warn: false,
},
{
name: "Docker daemon not available",
info: dockerInfo{ServerErrors: []string{"Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running"}},
Expand Down
2 changes: 1 addition & 1 deletion validators/types_unix.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ var DefaultSysSpec = SysSpec{
CgroupsV2Optional: []string{"hugetlb"},
RuntimeSpec: RuntimeSpec{
DockerSpec: &DockerSpec{
Version: []string{`1\.1[1-3]\..*`, `17\.0[3,6,9]\..*`, `18\.0[6,9]\..*`, `19\.03\..*`},
Version: []string{`1\.1[1-3]\..*`, `17\.0[3,6,9]\..*`, `18\.0[6,9]\..*`, `19\.03\..*`, `20\.10\..*`},
GraphDriver: []string{"aufs", "overlay", "overlay2", "devicemapper", "zfs"},
},
},
Expand Down
2 changes: 1 addition & 1 deletion validators/types_windows.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ var DefaultSysSpec = SysSpec{
},
RuntimeSpec: RuntimeSpec{
DockerSpec: &DockerSpec{
Version: []string{`18\.0[6,9]\..*`},
Version: []string{`18\.0[6,9]\..*`, `19\.03\..*`},
GraphDriver: []string{"windowsfilter"},
},
},
Expand Down

0 comments on commit ef4e32f

Please sign in to comment.