[Chore]: Replace Promtail with Grafana Alloy #97
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Parent Issue
Relates to #95
Summary
Replace the deprecated
mvp-promtailcontainer withmvp-alloyusing Grafana Alloy. This is the critical fix for the Docker API v1.44 incompatibility error that prevents container log collection.Root cause: Docker Engine v29 raised minimum API version to 1.44. Promtail 2.9.0 embeds Docker client API v1.42.
Files to Modify
1.
docker-compose.ymlRename service
mvp-promtailtomvp-alloy(lines 289-307):grafana/promtail:2.9.0->grafana/alloy:v1.12.2mvp-promtail->mvp-alloy./config/promtail/config.yml:/etc/promtail/config.yml:ro->./config/alloy/config.alloy:/etc/alloy/config.alloy/var/run/docker.sock:/var/run/docker.sock:ro)/var/lib/docker/containers:/var/lib/docker/containers:ro)depends_on: mvp-lokirun --server.http.listen-addr=0.0.0.0:12345 --storage.path=/var/lib/alloy/data /etc/alloy/config.alloy2. Create
config/alloy/config.alloy(NEW FILE)Replace
config/promtail/config.ymlwith Alloy-native configuration:3. Delete
config/promtail/config.ymlRemove the old Promtail configuration directory.
4.
.gitea/workflows/production.yaml(line 174)Update shared services start command:
Change to:
Acceptance Criteria
mvp-alloycontainer starts without Docker API version errorsDependencies
Milestone: Execution Complete
Phase: Execution | Agent: Platform | Status: PASS
Changes Made
M1: docker-compose.yml - Replaced
mvp-promtailservice withmvp-alloygrafana/promtail:2.9.0->grafana/alloy:v1.12.2mvp-promtail->mvp-alloyconfig/promtail/config.yml->config/alloy/config.alloyrunwith--server.http.listen-addr=0.0.0.0:12345and--storage.path=/var/lib/alloy/dataM2: config/alloy/config.alloy - Created Alloy-native configuration
discovery.dockerfor container auto-discovery via Docker socketdiscovery.relabelfor container name and compose service labelsloki.source.dockerforwarding toloki.write.defaultloki.writepushing tohttp://mvp-loki:3100/loki/api/v1/pushM3: config/promtail/ - Deleted old Promtail configuration directory
M4: .gitea/workflows/production.yaml - Updated shared services start command from
mvp-promtailtomvp-alloyM5: docs/LOGGING.md + CLAUDE.md - Updated all Promtail references to Alloy
Commit
1b20673-chore: replace Promtail with Grafana Alloy for log collection (refs #97)Verdict: PASS | Next: Quality review
egullickson referenced this issue2026-02-06 01:08:50 +00:00
QR Review: Post-Implementation
Phase: Review | Agent: Quality | Status: PASS
RULE 0 (CRITICAL) - Production Reliability
RULE 1 (HIGH) - Project Conformance
/readyon port 12345)RULE 2 (SHOULD_FIX) - Structural Quality
PR
#102
Verdict: PASS | Next: Merge PR