Merge pull request #72375 from sbezverk/containers_volumedevices

VolumeDevices validation and tests
This commit is contained in:
Kubernetes Prow Robot
2018-12-27 17:39:05 -08:00
committed by GitHub
4 changed files with 147 additions and 82 deletions

View File

@@ -2296,10 +2296,6 @@ func ValidateVolumeDevices(devices []core.VolumeDevice, volmounts map[string]str
devicepath := sets.NewString()
devicename := sets.NewString()
if devices != nil && !utilfeature.DefaultFeatureGate.Enabled(features.BlockVolume) {
allErrs = append(allErrs, field.Forbidden(fldPath.Child("volumeDevices"), "Container volumeDevices is disabled by feature-gate"))
return allErrs
}
if devices != nil {
for i, dev := range devices {
idxPath := fldPath.Index(i)