// Copyright (c) 2023 Volvo Car Corporation
// SPDX-License-Identifier: Apache-2.0

// Code generated by lingon. EDIT AS MUCH AS YOU LIKE.

package promstack

import (
	rbacv1 "k8s.io/api/rbac/v1"
	metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)

var KubePromtheusStackGrafanaCR = &rbacv1.ClusterRole{
	ObjectMeta: metav1.ObjectMeta{
		Labels: map[string]string{
			"app.kubernetes.io/instance":   "kube-promtheus-stack",
			"app.kubernetes.io/managed-by": "Helm",
			"app.kubernetes.io/name":       "grafana",
			"app.kubernetes.io/version":    "9.5.3",
			"helm.sh/chart":                "grafana-6.57.3",
		},
		Name: "kube-promtheus-stack-grafana-clusterrole",
	},
	Rules: []rbacv1.PolicyRule{{
		APIGroups: []string{""},
		Resources: []string{"configmaps", "secrets"},
		Verbs:     []string{"get", "watch", "list"},
	}},
	TypeMeta: metav1.TypeMeta{
		APIVersion: "rbac.authorization.k8s.io/v1",
		Kind:       "ClusterRole",
	},
}

var KubePromtheusStackKubeAdmissionCR = &rbacv1.ClusterRole{
	ObjectMeta: metav1.ObjectMeta{
		Annotations: map[string]string{
			"helm.sh/hook":               "pre-install,pre-upgrade,post-install,post-upgrade",
			"helm.sh/hook-delete-policy": "before-hook-creation,hook-succeeded",
		},
		Labels: map[string]string{
			"app":                          "kube-prometheus-stack-admission",
			"app.kubernetes.io/instance":   "kube-promtheus-stack",
			"app.kubernetes.io/managed-by": "Helm",
			"app.kubernetes.io/part-of":    "kube-prometheus-stack",
			"app.kubernetes.io/version":    "47.0.0",
			"chart":                        "kube-prometheus-stack-47.0.0",
			"heritage":                     "Helm",
			"release":                      "kube-promtheus-stack",
		},
		Name: "kube-promtheus-stack-kube-admission",
	},
	Rules: []rbacv1.PolicyRule{{
		APIGroups: []string{"admissionregistration.k8s.io"},
		Resources: []string{"validatingwebhookconfigurations", "mutatingwebhookconfigurations"},
		Verbs:     []string{"get", "update"},
	}},
	TypeMeta: metav1.TypeMeta{
		APIVersion: "rbac.authorization.k8s.io/v1",
		Kind:       "ClusterRole",
	},
}

var KubePromtheusStackKubeOperatorCR = &rbacv1.ClusterRole{
	ObjectMeta: metav1.ObjectMeta{
		Labels: map[string]string{
			"app":                          "kube-prometheus-stack-operator",
			"app.kubernetes.io/instance":   "kube-promtheus-stack",
			"app.kubernetes.io/managed-by": "Helm",
			"app.kubernetes.io/part-of":    "kube-prometheus-stack",
			"app.kubernetes.io/version":    "47.0.0",
			"chart":                        "kube-prometheus-stack-47.0.0",
			"heritage":                     "Helm",
			"release":                      "kube-promtheus-stack",
		},
		Name: "kube-promtheus-stack-kube-operator",
	},
	Rules: []rbacv1.PolicyRule{{
		APIGroups: []string{"monitoring.coreos.com"},
		Resources: []string{"alertmanagers", "alertmanagers/finalizers", "alertmanagers/status", "alertmanagerconfigs", "prometheuses", "prometheuses/finalizers", "prometheuses/status", "prometheusagents", "prometheusagents/finalizers", "prometheusagents/status", "thanosrulers", "thanosrulers/finalizers", "thanosrulers/status", "scrapeconfigs", "servicemonitors", "podmonitors", "probes", "prometheusrules"},
		Verbs:     []string{"*"},
	}, {
		APIGroups: []string{"apps"},
		Resources: []string{"statefulsets"},
		Verbs:     []string{"*"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"configmaps", "secrets"},
		Verbs:     []string{"*"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"pods"},
		Verbs:     []string{"list", "delete"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"services", "services/finalizers", "endpoints"},
		Verbs:     []string{"get", "create", "update", "delete"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"nodes"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"namespaces"},
		Verbs:     []string{"get", "list", "watch"},
	}, {
		APIGroups: []string{"networking.k8s.io"},
		Resources: []string{"ingresses"},
		Verbs:     []string{"get", "list", "watch"},
	}},
	TypeMeta: metav1.TypeMeta{
		APIVersion: "rbac.authorization.k8s.io/v1",
		Kind:       "ClusterRole",
	},
}

var KubePromtheusStackKubePrometheusCR = &rbacv1.ClusterRole{
	ObjectMeta: metav1.ObjectMeta{
		Labels: map[string]string{
			"app":                          "kube-prometheus-stack-prometheus",
			"app.kubernetes.io/instance":   "kube-promtheus-stack",
			"app.kubernetes.io/managed-by": "Helm",
			"app.kubernetes.io/part-of":    "kube-prometheus-stack",
			"app.kubernetes.io/version":    "47.0.0",
			"chart":                        "kube-prometheus-stack-47.0.0",
			"heritage":                     "Helm",
			"release":                      "kube-promtheus-stack",
		},
		Name: "kube-promtheus-stack-kube-prometheus",
	},
	Rules: []rbacv1.PolicyRule{{
		APIGroups: []string{""},
		Resources: []string{"nodes", "nodes/metrics", "services", "endpoints", "pods"},
		Verbs:     []string{"get", "list", "watch"},
	}, {
		APIGroups: []string{"networking.k8s.io"},
		Resources: []string{"ingresses"},
		Verbs:     []string{"get", "list", "watch"},
	}, {
		NonResourceURLs: []string{"/metrics", "/metrics/cadvisor"},
		Verbs:           []string{"get"},
	}},
	TypeMeta: metav1.TypeMeta{
		APIVersion: "rbac.authorization.k8s.io/v1",
		Kind:       "ClusterRole",
	},
}

var KubePromtheusStackKubeStateMetricsCR = &rbacv1.ClusterRole{
	ObjectMeta: metav1.ObjectMeta{
		Labels: map[string]string{
			"app.kubernetes.io/component":  "metrics",
			"app.kubernetes.io/instance":   "kube-promtheus-stack",
			"app.kubernetes.io/managed-by": "Helm",
			"app.kubernetes.io/name":       "kube-state-metrics",
			"app.kubernetes.io/part-of":    "kube-state-metrics",
			"app.kubernetes.io/version":    "2.9.2",
			"helm.sh/chart":                "kube-state-metrics-5.7.0",
			"release":                      "kube-promtheus-stack",
		},
		Name: "kube-promtheus-stack-kube-state-metrics",
	},
	Rules: []rbacv1.PolicyRule{{
		APIGroups: []string{"certificates.k8s.io"},
		Resources: []string{"certificatesigningrequests"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"configmaps"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"batch"},
		Resources: []string{"cronjobs"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"extensions", "apps"},
		Resources: []string{"daemonsets"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"extensions", "apps"},
		Resources: []string{"deployments"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"endpoints"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"autoscaling"},
		Resources: []string{"horizontalpodautoscalers"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"extensions", "networking.k8s.io"},
		Resources: []string{"ingresses"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"batch"},
		Resources: []string{"jobs"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"coordination.k8s.io"},
		Resources: []string{"leases"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"limitranges"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"admissionregistration.k8s.io"},
		Resources: []string{"mutatingwebhookconfigurations"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"namespaces"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"networking.k8s.io"},
		Resources: []string{"networkpolicies"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"nodes"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"persistentvolumeclaims"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"persistentvolumes"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"policy"},
		Resources: []string{"poddisruptionbudgets"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"pods"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"extensions", "apps"},
		Resources: []string{"replicasets"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"replicationcontrollers"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"resourcequotas"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"secrets"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{""},
		Resources: []string{"services"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"apps"},
		Resources: []string{"statefulsets"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"storage.k8s.io"},
		Resources: []string{"storageclasses"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"admissionregistration.k8s.io"},
		Resources: []string{"validatingwebhookconfigurations"},
		Verbs:     []string{"list", "watch"},
	}, {
		APIGroups: []string{"storage.k8s.io"},
		Resources: []string{"volumeattachments"},
		Verbs:     []string{"list", "watch"},
	}},
	TypeMeta: metav1.TypeMeta{
		APIVersion: "rbac.authorization.k8s.io/v1",
		Kind:       "ClusterRole",
	},
}
