Jesse Adelman:
Just want to say I appreciate the OPA coverage here - it may not be in the actual exam, but OPA is a really neat project.
unnivkn:
The above Image pull error message is expected, since that image not exists… Only thing we need to make sure, it pass the admission control error message.
unnivkn:
root@controlplane:~# k -n dev apply -f /root/test.yaml
Error from server (image ‘nginx’ comes from untrusted registry): error when creating “/root/test.yaml”: admission webhook “http://validating-webhook.openpolicyagent.org|validating-webhook.openpolicyagent.org” denied the request: image ‘nginx’ comes from untrusted registry
root@controlplane:~#
unnivkn:
After updated the yaml: root@controlplane:~# k -n dev apply -f /root/test.yaml
pod/test created
root@controlplane:~#