Glad that you have reached that far (
vi restrictinbound.yaml) from our YouTube channel and now set this metada:
Then apply it
k apply -f restrict-inbound.yaml
k get networkpolicies.networking.k8s.io
Delete the busybox pod:
k delete po busybox --force
Now you might see this while pressing the check button.
Now copy this part from the apparmor page.
annotations: # Tell Kubernetes to apply the AppArmor profile "k8s-apparmor-example-deny-write". # Note that this is ignored if the Kubernetes node is not running version 1.4 or greater. container.apparmor.security.beta.kubernetes.io/hello: localhost/k8s-apparmor-example-deny-write
Then go to here:
k edit deployments.apps alpha-xyz
after app: alpha-xyz, paste this part.
Then annotate it properly and then use nginx image here.
Moreover, you have to right the annotations and then use custom-nginx image.
We are done!
Top comments (0)