homelab/roles/monitoring/tasks/postgresql.yml

14 lines
414 B
YAML
Raw Normal View History

2024-10-15 21:56:15 +05:00
---
- name: Run postgresql exporter
become: true
community.docker.docker_container:
name: postgresql-exporter
image: quay.io/prometheuscommunity/postgres-exporter:v0.15.0
networks:
- name: monitoring
- name: postgresql
env:
DATA_SOURCE_URI: postgresql:5432/exporter?sslmode=disable
DATA_SOURCE_USER: exporter
DATA_SOURCE_PASS: "{{ postgresql_exporter_password }}"