Vinyeh's picture
Add pinned source: gatekeeper-library (part 7)
df0899b verified
Raw History Blame Contribute Delete
579 Bytes
variables:
- name: sharingHostIPC
expression: |
has(variables.anyObject.spec.hostIPC) ? variables.anyObject.spec.hostIPC : false
- name: sharingHostPID
expression: |
has(variables.anyObject.spec.hostPID) ? variables.anyObject.spec.hostPID : false
- name: sharingNamespace
expression: |
variables.sharingHostIPC || variables.sharingHostPID
validations:
- expression: '(has(request.operation) && request.operation == "UPDATE") || !variables.sharingNamespace'
messageExpression: '"Sharing the host namespace is not allowed: " + variables.anyObject.metadata.name'