Skip to content

Commit

Permalink
fix: csi is an allowed volume type
Browse files Browse the repository at this point in the history
Signed-off-by: Joe Bowbeer <[email protected]>
  • Loading branch information
joebowbeer committed Dec 11, 2023
1 parent cc507c7 commit 08234b9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ disallowed_volume_types = [
"portworxVolume",
"scaleIO",
"storageos",
"csi",
]

# getDisallowedVolumes returns a list of volume names
Expand All @@ -71,6 +70,6 @@ failVolumeTypes {

deny[res] {
failVolumeTypes
msg := kubernetes.format(sprintf("%s '%s' should set 'spec.volumes[*]' to type 'PersistentVolumeClaim'", [kubernetes.kind, kubernetes.name]))
msg := kubernetes.format(sprintf("%s '%s' should set 'spec.volumes[*]' to an allowed volume type", [kubernetes.kind, kubernetes.name]))
res := result.new(msg, input.spec)
}
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ test_disallowed_volume_type_used_denied {
}

count(r) == 1
r[_].msg == "Pod 'hello-volume-types' should set 'spec.volumes[*]' to type 'PersistentVolumeClaim'"
r[_].msg == "Pod 'hello-volume-types' should set 'spec.volumes[*]' to an allowed volume type"
}

test_no_volume_type_used_allowed {
Expand Down

0 comments on commit 08234b9

Please sign in to comment.