apiVersion: v1
kind: ConfigMap
metadata:
  name: prometheus
  labels:
    grafana_datasource: "1"
data:
  datasource.yaml: |-
    # config file version
    apiVersion: 1
    datasources:
      # <string, required> name of the datasource. Required
    - name: Prometheus
      # <string, required> datasource type. Required
      type: prometheus
      # <string, required> access mode. proxy or direct (Server or Browser in the UI). Required
      access: proxy
      # <bool> mark as default datasource. Max one per org
      isDefault: true
      # <int> org id. will default to orgId 1 if not specified
      orgId: 1
      # <string> url
      url: http://prometheus-operated:9090 #http://localhost:9090
      # <map> fields that will be converted to json and stored in json_data
      jsonData:
        timeInterval: "15s"
      version: 1
      # <bool> allow users to edit datasources from the UI.
      editable: true
