2019-03-21 16:09:14 +00:00
|
|
|
package config
|
2019-03-21 13:57:30 +00:00
|
|
|
|
|
|
|
const (
|
|
|
|
// These constants MUST be equal to the corresponding names in service definition in definitions/install.yaml
|
2019-05-22 01:36:24 +00:00
|
|
|
KubePolicyNamespace = "kyverno"
|
|
|
|
WebhookServiceName = "kyverno-svc"
|
2019-05-14 14:58:59 +00:00
|
|
|
|
2019-05-22 01:36:24 +00:00
|
|
|
MutatingWebhookConfigurationName = "kyverno-mutating-webhook-cfg"
|
|
|
|
MutatingWebhookName = "nirmata.kyverno.mutating-webhook"
|
2019-05-14 14:58:59 +00:00
|
|
|
|
2019-05-22 01:36:24 +00:00
|
|
|
ValidatingWebhookConfigurationName = "kyverno-validating-webhook-cfg"
|
|
|
|
ValidatingWebhookName = "nirmata.kyverno.validating-webhook"
|
2019-03-21 13:57:30 +00:00
|
|
|
|
2019-03-25 13:44:53 +00:00
|
|
|
// Due to kubernetes issue, we must use next literal constants instead of deployment TypeMeta fields
|
2019-05-14 14:58:59 +00:00
|
|
|
// Issue: https://github.com/kubernetes/kubernetes/pull/63972
|
|
|
|
// When the issue is closed, we should use TypeMeta struct instead of this constants
|
|
|
|
DeploymentKind = "Deployment"
|
|
|
|
DeploymentAPIVersion = "extensions/v1beta1"
|
2019-05-22 01:36:24 +00:00
|
|
|
KubePolicyDeploymentName = "kyverno-deployment"
|
2019-03-21 13:57:30 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
var (
|
2019-05-14 14:58:59 +00:00
|
|
|
MutatingWebhookServicePath = "/mutate"
|
|
|
|
ValidatingWebhookServicePath = "/validate"
|
|
|
|
KubePolicyAppLabels = map[string]string{
|
2019-05-22 01:36:24 +00:00
|
|
|
"app": "kyverno",
|
2019-03-21 13:57:30 +00:00
|
|
|
}
|
2019-05-14 14:58:59 +00:00
|
|
|
|
|
|
|
SupportedKinds = []string{
|
|
|
|
"ConfigMap",
|
|
|
|
"CronJob",
|
|
|
|
"DaemonSet",
|
|
|
|
"Deployment",
|
|
|
|
"Endpoints",
|
|
|
|
"HorizontalPodAutoscaler",
|
|
|
|
"Ingress",
|
|
|
|
"Job",
|
|
|
|
"LimitRange",
|
|
|
|
"Namespace",
|
|
|
|
"NetworkPolicy",
|
|
|
|
"PersistentVolumeClaim",
|
|
|
|
"PodDisruptionBudget",
|
|
|
|
"PodTemplate",
|
|
|
|
"ResourceQuota",
|
|
|
|
"Secret",
|
|
|
|
"Service",
|
|
|
|
"StatefulSet",
|
|
|
|
}
|
2019-03-25 13:44:53 +00:00
|
|
|
)
|