I'd like to investigate an issue with nginx-ingress
on a GKE cluster. Therefore I need to enable admission controller and was wondering whether this is possible on GKE. I'm creating the cluster with
[authentication boilerplate]
gcloud container clusters create cluster-name --machine-type=n1-standard-1 --no-enable-stackdriver-kubernetes --no-enable-autoupgrade --preemptible
I find no option in gcloud --help
or gcloud container clusters create --help
.
I need to enable the admission controller for service accounts.
You can use gcloud beta like this:
gcloud beta container clusters create [CLUSTER_NAME] --enable-pod-security-policy
Or you can use update:
gcloud beta container clusters update [CLUSTER_NAME] --enable-pod-security-policy
This page explains how to use PodSecurityPolicies in Google Kubernetes Engine.