chore: remove config.yaml mount from docker-compose; update config example
- Replace individual volume mounts (playbook_cache, plugins) with single app_data:/data mount - Change FABLEDNETMON_DATABASE__URL to FABLEDNETMON_DATABASE_URL (underscore to hyphen) - Simplify config.example.yaml to focus on required database URL setting - Document that other settings are now managed via the Settings UI Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+16
-31
@@ -1,36 +1,21 @@
|
|||||||
# FabledNetMon configuration example
|
# FabledNetMon — Bootstrap Configuration Example
|
||||||
# Copy to config.yaml and fill in your values.
|
#
|
||||||
# Secrets can be set via env vars: FABLEDNETMON_<UPPER__PATH>
|
# The only REQUIRED setting is the database URL.
|
||||||
|
# Set it via env var (recommended for Docker):
|
||||||
secret_key: "change-me-to-a-random-string"
|
#
|
||||||
|
# FABLEDNETMON_DATABASE_URL=postgresql+asyncpg://user:pass@host/db
|
||||||
|
#
|
||||||
|
# All other settings (SMTP, webhook, ansible, plugins, retention)
|
||||||
|
# are stored in the database and managed via the Settings UI at /settings/.
|
||||||
|
#
|
||||||
|
# config.yaml is optional. Use it only if you prefer file-based bootstrap.
|
||||||
|
|
||||||
database:
|
database:
|
||||||
url: "postgresql+asyncpg://fablednetmon:password@localhost/fablednetmon"
|
url: "postgresql+asyncpg://fablednetmon:password@localhost/fablednetmon"
|
||||||
|
|
||||||
session:
|
# Optional: override the auto-generated secret key.
|
||||||
lifetime_hours: 8
|
# If not set, a key is auto-generated on first run and saved to /data/secret.key.
|
||||||
|
# secret_key: "change-me-to-a-random-string"
|
||||||
|
|
||||||
data:
|
# Optional: path to plugin directory (default: "plugins")
|
||||||
retention_days: 90
|
# plugin_dir: "./plugins"
|
||||||
|
|
||||||
# plugin_dir: ./plugins # optional; defaults to ./plugins relative to config.yaml
|
|
||||||
|
|
||||||
plugins: {}
|
|
||||||
# traefik:
|
|
||||||
# enabled: true
|
|
||||||
# metrics_url: "http://localhost:8080/metrics"
|
|
||||||
# scrape_interval_seconds: 60
|
|
||||||
|
|
||||||
smtp:
|
|
||||||
host: ""
|
|
||||||
port: 587
|
|
||||||
tls: true
|
|
||||||
username: ""
|
|
||||||
password: "" # or: FABLEDNETMON_SMTP__PASSWORD env var
|
|
||||||
recipients: []
|
|
||||||
# - admin@example.com
|
|
||||||
|
|
||||||
webhook:
|
|
||||||
url: "" # leave empty to disable
|
|
||||||
template: |
|
|
||||||
{"content": "**{{ alert.state }}** — {{ alert.resource }} — {{ alert.rule_name }} ({{ alert.metric }} = {{ alert.value }})"}
|
|
||||||
|
|||||||
+3
-6
@@ -4,11 +4,9 @@ services:
|
|||||||
ports:
|
ports:
|
||||||
- "5000:5000"
|
- "5000:5000"
|
||||||
volumes:
|
volumes:
|
||||||
- ./config.yaml:/config/config.yaml:ro
|
- app_data:/data
|
||||||
- playbook_cache:/data/playbook_cache
|
|
||||||
- plugins:/data/plugins
|
|
||||||
environment:
|
environment:
|
||||||
- FABLEDNETMON_DATABASE__URL=postgresql+asyncpg://fablednetmon:fablednetmon@db/fablednetmon
|
- FABLEDNETMON_DATABASE_URL=postgresql+asyncpg://fablednetmon:fablednetmon@db/fablednetmon
|
||||||
depends_on:
|
depends_on:
|
||||||
db:
|
db:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
@@ -31,5 +29,4 @@ services:
|
|||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
pgdata:
|
pgdata:
|
||||||
playbook_cache:
|
app_data:
|
||||||
plugins:
|
|
||||||
|
|||||||
Reference in New Issue
Block a user