apiVersion: admissionregistration.k8s.io/v1
kind: MutatingWebhookConfiguration
metadata:
  name: mutating-gtoken-webhook-cfg
  labels:
    app: gtoken-webhook
webhooks:
  - name: gtoken.kubeneretes.io
    sideEffects: None
    admissionReviewVersions: ["v1beta1"]
    clientConfig:
      service:
        name: gtoken-webhook-svc
        namespace: ${NAMESPACE}
        path: "/pods"
      caBundle: ${CA_BUNDLE}
    rules:
      - operations: ["CREATE"]
        apiGroups: ["*"]
        apiVersions: ["*"]
        resources: ["pods"]
