mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 03:11:40 +00:00
Respect ignore-volume-az option in admission plugin
We appear to be respecting this options when provisioning the volume but when PV is admitted the zone/region fields get added back to the PV and hence defeating the purpose of the option.
This commit is contained in:
parent
4e8a7f4a4b
commit
ea5bea2b9f
@ -726,6 +726,11 @@ func (os *OpenStack) GetLabelsForVolume(ctx context.Context, pv *v1.PersistentVo
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
// if volume az is to be ignored we should return nil from here
|
||||
if os.bsOpts.IgnoreVolumeAZ {
|
||||
return nil, nil
|
||||
}
|
||||
|
||||
// Get Volume
|
||||
volume, err := os.getVolume(pv.Spec.Cinder.VolumeID)
|
||||
if err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user