mirror of
https://github.com/kyverno/kyverno.git
synced 2025-03-29 10:55:05 +00:00
update best-practice run as non-root uesr
This commit is contained in:
parent
5e0415911a
commit
f4eee4b30a
3 changed files with 10 additions and 9 deletions
|
@ -20,9 +20,8 @@ spec:
|
|||
- spec:
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
||||
# pattern:
|
||||
# spec:
|
||||
# containers:
|
||||
# - name: "*"
|
||||
# securityContext:
|
||||
# runAsNonRoot: true
|
||||
- spec:
|
||||
containers:
|
||||
- name: "*"
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
|
@ -3,8 +3,10 @@ kind: Pod
|
|||
metadata:
|
||||
name: check-root-user
|
||||
spec:
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
||||
# securityContext:
|
||||
# runAsNonRoot: true
|
||||
containers:
|
||||
- name: check-root-user
|
||||
image: nginxinc/nginx-unprivileged
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
||||
|
|
|
@ -14,6 +14,6 @@ expected:
|
|||
rules:
|
||||
- name: deny-runasrootuser
|
||||
type: Validation
|
||||
message: "Validation rule 'deny-runasrootuser' anyPattern[0] succesfully validated"
|
||||
message: "Validation rule 'deny-runasrootuser' anyPattern[1] succesfully validated"
|
||||
success: true
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue