Skip to content

Commit

Permalink
Monitoring setup (#606)
Browse files Browse the repository at this point in the history
I think that I now understand how prometheus docker host was supposed to
be used. It seems to work fine.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

This update enhances system observability and functionality through new
service integrations and configuration improvements:

- **New Features**
	- Introduced a dedicated validation service.
- Added a Grafana dashboard offering anonymous access with persistent
storage.
- **Updates**
	- Upgraded the monitoring service with a modern image.
	- Renamed the monitoring job identifier for improved organization.
- **Chores**
	- Enabled metrics support via additional environment variables.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
  • Loading branch information
mkysel authored Mar 10, 2025
1 parent 0be95dc commit f5512cd
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 7 deletions.
25 changes: 20 additions & 5 deletions dev/docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,30 @@ services:
ports:
- 7545:8545

validation:
image: ghcr.io/xmtp/mls-validation-service:main
platform: linux/amd64
ports:
- 60051:50051


prometheus:
image: prom/prometheus
image: ubuntu/prometheus
ports:
- 9090:9090
volumes:
- ./prometheus.yml:/etc/prometheus/prometheus.yml

validation:
image: ghcr.io/xmtp/mls-validation-service:main
platform: linux/amd64
grafana:
image: grafana/grafana
ports:
- 60051:50051
- "3000:3000"
volumes:
- grafana_data:/var/lib/grafana
environment:
- GF_AUTH_ANONYMOUS_ENABLED=true
- GF_AUTH_ANONYMOUS_ORG_NAME=Viewer
- GF_AUTH_ANONYMOUS_ORG_ROLE=Viewer

volumes:
grafana_data:
4 changes: 2 additions & 2 deletions dev/docker/prometheus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ global:
scrape_interval: 10s

scrape_configs:
- job_name: prometheus
- job_name: xmtpd
static_configs:
- targets:
- "host.docker.internal:8008"
- "host.docker.internal:8009"
- "host.docker.internal:8009"
2 changes: 2 additions & 0 deletions dev/run
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,7 @@ export XMTPD_PAYER_ENABLE=true
export XMTPD_REPLICATION_ENABLE=true
export XMTPD_SYNC_ENABLE=true
export XMTPD_INDEXER_ENABLE=true
export XMTPD_METRICS_ENABLE=true
export XMTPD_METRICS_METRICS_ADDRESS=0.0.0.0

go run -ldflags="-X main.Version=$(git describe HEAD --tags --long)" cmd/replication/main.go "$@"

0 comments on commit f5512cd

Please sign in to comment.