nginx/CrowdSec Logs: Normalize Them with Vector
In short
Two problems coexisted in BetterStack: mcp-oauth.access.log logs arrived as unreadable raw JSON, and CrowdSec logs produced visual duplicates. This work normalizes all logs so they display as structured clickable tags, with correct timestamps and without parasitic fields.
🧠 Why
BetterStack displays logs as highlighted clickable tags in the Live Tail when JSON fields are properly structured. Before this work, observation was degraded on two fronts:
mcp-oauth.access.loglogs arrived as unreadable raw JSON (custom format incompatible with Vector’s nginx parser) — fieldsnginx.client,nginx.path,nginx.statuswere not extracted- CrowdSec and CF WAF logs arrived as plain text with duplicates (
Ban ban | ... | Ban ban)
The goal was to normalize all logs in BetterStack to display like standard nginx logs:



