genpolicy: ignore volume configMap optional field

The auto-generated Policy already allows these volumes to be mounted,
regardless if they are:
- Present, or
- Missing and optional

Fixes: #8893

Signed-off-by: Dan Mihai <dmihai@microsoft.com>
This commit is contained in:
Dan Mihai
2024-01-30 02:21:11 +00:00
parent 087856f26c
commit d12875ee66

View File

@@ -71,6 +71,7 @@ pub struct PersistentVolumeClaimVolumeSource {
pub struct ConfigMapVolumeSource { pub struct ConfigMapVolumeSource {
pub name: String, pub name: String,
pub items: Option<Vec<KeyToPath>>, pub items: Option<Vec<KeyToPath>>,
optional: Option<bool>,
// TODO: additional fields. // TODO: additional fields.
} }