Skip to main content
View rawEdit

Configuration

Configuration guides for customizing PostgresAI monitoring components.

Components​

ComponentPurposeConfiguration scope
pgwatchMetrics collectionCollection intervals, custom metrics
VictoriaMetricsTime-series storageRetention, storage, scrape settings
GrafanaVisualizationDashboards, data sources, authentication
AlertingNotificationsAlert rules, notification channels

Configuration methods​

CLI installation​

Configuration via environment variables and command-line flags:

postgresai mon local-install \
--retention 30d \
--scrape-interval 15s \
postgresql://user@host:5432/db

Docker Compose​

Configuration via docker-compose.yml and environment files:

services:
pgwatch:
environment:
PW_SCRAPE_INTERVAL: 15s
PW_RETENTION: 720h

Helm​

Configuration via values.yaml:

monitoring:
retention: 30d
scrapeInterval: 15s

Quick reference​

SettingDefaultDescription
Scrape interval15sHow often to collect metrics
Retention14dHow long to keep metrics
Max connections3Connections per monitored database

Sections​