blob: dc76aefb8ba2d2896a72929e8a843e957a96ca9d [file] [log] [blame]
---
# Copyright 2018-present Open Networking Foundation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
{{- if .Values.grafana.enabled }}
apiVersion: v1
kind: ConfigMap
metadata:
name: grafana-config
data:
grafana.ini: |
{{ .Files.Get "configs/grafana.ini" | indent 4 }}
ldap.toml: |
{{ .Files.Get "configs/ldap.toml" | indent 4 }}
---
apiVersion: v1
kind: ConfigMap
metadata:
name: grafana-dashs
labels:
grafana_dashboard: "1"
data:
cdn_metrics.json: |
{{ .Files.Get "configs/cdn-metrics.json" | indent 4 }}
---
apiVersion: v1
kind: ConfigMap
metadata:
name: grafana-dash-provider
labels:
grafana_dashboard: "1"
data:
dashboard.yaml: |
apiVersion: 1
providers:
- name: 'default'
orgId: 1
folder: ''
type: file
disableDeletion: false
updateIntervalSeconds: 3
options:
path: /etc/grafana/dashboards
---
apiVersion: v1
kind: ConfigMap
metadata:
name: grafana-datasources-provider
data:
prometheus-datasource.yaml: |
datasources:
- access: 'proxy'
editable: true
is_default: true
name: 'prom'
org_id: 1
type: 'prometheus'
url: http://{{ .Values.prometheus_host }}:{{ .Values.prometheus.nodePort }}
{{- end }}