apiVersion: helm.toolkit.fluxcd.io/v2
kind: HelmRelease
metadata:
  name: postgres-exporter
  namespace: postgres-exporter
spec:
  dependsOn:
    - name: prometheus-stack
      namespace: prometheus-stack
  interval: 5m
  timeout: 10m
  chart:
    spec:
      version: 0.0.2-prod
  values:
    image:
      name: cr.yandex/crp3ccidau046kdj8g9q/postgres-exporter:preprod_21350302
      pullPolicy: IfNotPresent
      pullSecrets:
        - dockerhub
    serviceMonitor:
      enabled: true
      namespace: postgres-exporter
    config:
      datasource:
        host: 192.168.2.45
        user: root
        port: '5432'
        database: postgres
        sslmode: disable
    datasources:
      - name: attachments
        uri: 192.168.2.45:5432/attachments_db?sslmode=disable
      - name: checklists
        uri: 192.168.2.45:5432/checklists?sslmode=disable
      - name: comparisons
        uri: 192.168.2.45:5432/comparisons_db?sslmode=disable
      - name: contracts
        uri: 192.168.2.45:5432/contracts?sslmode=disable
      - name: django
        uri: 192.168.2.45:5432/sarex_db?sslmode=disable
      - name: documentations
        uri: 192.168.2.45:5432/documentations?sslmode=disable
      - name: drawings
        uri: 192.168.2.45:5432/drawings?sslmode=disable
      - name: eav
        uri: 192.168.2.45:5432/eav?sslmode=disable
      - name: flows
        uri: 192.168.2.45:5432/flows_db?sslmode=disable
      - name: gitea
        uri: 192.168.2.45:5432/gitea?sslmode=disable
      - name: goalert
        uri: 192.168.2.45:5432/goalert?sslmode=disable
      - name: inspections
        uri: 192.168.2.45:5432/inspections_db?sslmode=disable
      - name: issues
        uri: 192.168.2.45:5432/issues?sslmode=disable
      - name: notes
        uri: 192.168.2.45:5432/notes_db?sslmode=disable
      - name: openobserve
        uri: 192.168.2.45:5432/openobserve?sslmode=disable
      - name: postgres
        uri: 192.168.2.45:5432/postgres?sslmode=disable
      - name: pm
        uri: 192.168.2.45:5432/pm?sslmode=disable
      - name: resources
        uri: 192.168.2.45:5432/resources?sslmode=disable
      - name: rfi
        uri: 192.168.2.45:5432/rfi_db?sslmode=disable
      - name: subscriptions
        uri: 192.168.2.45:5432/subscriptions?sslmode=disable
      - name: system-log
        uri: 192.168.2.45:5432/system_log?sslmode=disable
      - name: transmittal
        uri: 192.168.2.45:5432/transmittal_db?sslmode=disable
      - name: workflow
        uri: 192.168.2.45:5432/workflows_db?sslmode=disable
      - name: workspaces
        uri: 192.168.2.45:5432/workspaces_db?sslmode=disable
      - name: zitadel
        uri: 192.168.2.45:5432/zitadel?sslmode=disable
