apiVersion: admissionregistration.k8s.io/v1
kind: MutatingWebhookConfiguration
metadata:
  name: sidecar-injector-webhook-cfg
  labels:
    app: sidecar-injector
  annotations:
    service.beta.openshift.io/inject-cabundle: "true"
webhooks:
- name: admission.xphyr.net
  clientConfig:
    service:
      name: sidecar-injector-webhook-svc
      namespace: sidecar-injector
      path: "/mutate"
  rules:
  - operations: ["CREATE", "UPDATE"]
    apiGroups: [""]
    apiVersions: ["v1"]
    resources: ["pods"]
  namespaceSelector:
    matchLabels:
      sidecar-injection: enabled
  admissionReviewVersions: ["v1"]
  sideEffects: None
  timeoutSeconds: 5
