# -- If the operator should run in namespace-scope or not,
# if true the operator will only be able to manage instances in the same namespace
namespaceScope: false

# -- If you want to run multiple replicas of the grafana-operator, this is not recommended.
leaderElect: false

# -- Sets the WATCH_NAMESPACE environment variable,
# it defines which namespaces the operator should be listening for.
# By default it's all namespaces, if you only want to listen for the same namespace as the operator is deployed to look at namespaceScope.
watchNamespaces: ""

# -- Sets the WATCH_NAMESPACE_SELECTOR environment variable,
# it defines which namespaces the operator should be listening for based on label and key value pair added on namespace kind.
# By default it's all namespaces.
watchNamespaceSelector: ""

# -- Determines if the target cluster is OpenShift. Additional rbac permissions for routes will be added on OpenShift
isOpenShift: false

# -- Additional environment variables
env: []
  # -- grafana image, e.g. docker.io/grafana/grafana:9.1.6, overwrites the default grafana image defined in the operator
  # - name: RELATED_IMAGE_GRAFANA
  #   value: "docker.io/grafana/grafana:9.1.6"
  # - name: MY_VAR
  #   value: "myvalue"

image:
  # -- grafana operator image repository
  repository: ghcr.io/grafana/grafana-operator
  # -- The image pull policy to use in grafana operator container
  pullPolicy: IfNotPresent
  # -- Overrides the image tag whose default is the chart appVersion.
  tag: ""

# -- image pull secrets
imagePullSecrets: []

# -- Overrides the name of the chart.
nameOverride: ""

# -- Overrides the fully qualified app name.
fullnameOverride: ""

# -- Overrides the namespace name.
namespaceOverride: ""

serviceAccount:
  # -- Specifies whether a service account should be created
  create: true
  # -- Annotations to add to the service account
  annotations: {}
  # -- The name of the service account to use.
  # If not set and create is true, a name is generated using the fullname template
  name: ""

rbac:
  # -- Specifies whether to create the ClusterRole and ClusterRoleBinding.
  # If "namespaceScope" is true or "watchNamespaces" is set, this will create Role and RoleBinding instead.
  create: true

metricsService:
  # -- metrics service type
  type: ClusterIP
  # -- metrics service port
  metricsPort: 9090
  # -- port for the pprof profiling endpoint
  pprofPort: 8888

# -- additional labels to add to all resources
additionalLabels: {}

# -- pod annotations
podAnnotations: {}

# -- pod security context
podSecurityContext: {}

# -- grafana operator container security context
securityContext:
  capabilities:
    drop:
      - ALL
  readOnlyRootFilesystem: true
  runAsNonRoot: true

# -- grafana operator container resources
resources: {}

# -- pod priority class name
priorityClassName: ""

# -- pod node selector
nodeSelector: {}

# -- pod tolerations
tolerations: []

# -- pod affinity
affinity: {}

# -- Enable this to use with Prometheus Operator
serviceMonitor:
  # -- When set true then use a ServiceMonitor to configure scraping
  enabled: false
  # -- Set of labels to transfer from the Kubernetes Service onto the target
  additionalLabels: {}
  # -- Set how frequently Prometheus should scrape
  interval: 1m
  # -- Set timeout for scrape
  scrapeTimeout: 10s
  # -- Set path to metrics path
  telemetryPath: /metrics
  # -- Set of labels to transfer from the Kubernetes Service onto the target
  targetLabels: []
  # -- MetricRelabelConfigs to apply to samples before ingestion
  metricRelabelings: []
  # -- Set relabel_configs as per https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config
  relabelings: []

# -- Array of extra K8s objects to deploy
extraObjects: []
# - apiVersion: external-secrets.io/v1beta1
#   kind: ExternalSecret
#   metadata:
#     name: grafana-operator-apikey
#   spec:
#     refreshInterval: 1h
#     secretStoreRef:
#       kind: SecretStore
#       name: my-secret-store
#     target:
#       template:
#         data:
#           GRAFANA_CLOUD_INSTANCE_TOKEN: "{{`{{ .Token }}`}}"
#     dataFrom:
#     - extract:
#         key: my-secret-store-secret

