Skip to content

Commit c94fa0c

Browse files
Update volumes.md
Had a typo :( in the earlier PR - #45501. Test output - ``` kubectl apply -f gitrepovol.yaml Warning: spec.volumes[1].gitRepo: deprecated in v1.11 The pods "gitrepo-volume-pod" is invalid: : ValidatingAdmissionPolicy 'deprecated-gitrepo-volumes.example.com' with binding 'deprecated-gitrepo-volumes-binding.example.com' denied request: Pod must not use deprecated spec.volumes[].gitRepo field. kubectl get ValidatingAdmissionPolicy -oyaml | grep 'expression' - expression: has(object.spec.volumes) && !object.spec.volumes.exists(v, has(v.gitRepo)) ```
1 parent 2fed611 commit c94fa0c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

content/en/docs/concepts/storage/volumes.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -326,7 +326,7 @@ You can restrict the use of `gitRepo` volumes in your cluster using
326326
[ValidatingAdmissionPolicy](/docs/reference/access-authn-authz/validating-admission-policy/).
327327
You can use the following Common Expression Language (CEL) expression as
328328
part of a policy to reject use of `gitRepo` volumes:
329-
`!has(object.spec.volumes) || !object.spec.volumes.exists(v, has(v.gitRepo))`.
329+
`has(object.spec.volumes) || !object.spec.volumes.exists(v, has(v.gitRepo))`.
330330

331331
{{< /warning >}}
332332

0 commit comments

Comments
 (0)