Refer to
.env.example
- Add Grafana credentials to
.env:
# Grafana credentials
GF_SECURITY_ADMIN_USER=your_login
GF_SECURITY_ADMIN_PASSWORD=your_secure_password
- Optionally, if you want to enable alerts sent to Telegram, you can add Telegram bot details to
.env:
# Telegram bot details
TELEGRAM_BOT_TOKEN=your_telegram_bot_api_key
TELEGRAM_CHAT_ID=your_telegram_chat_id
Here is how to get the chat ID.
And uncomment the provisioned alert rule in /monitoring/grafana/provisioning/alerting/alerts.yaml. Or you can create everything in the UI.
-
Optionally, if you want to use a Google Bucket for logs storage, or deploying this in production add a service account key – a
.jsonfile you get here – under/monitoringdirectory. Refer to the blog post on how to get the service account key. -
Run the appropriate compose file with the
monitoringprofile (run inside root folder):
docker compose --profile monitoring up -d| Service | Addresses |
|---|---|
| Grafana | localhost:3000 |
| Prometheus | localhost:9090 |
| Alloy | localhost:12345 |
| Loki (No UI, if running 404 page not found is displayed) |
localhost:3100 |
In production, if you are using the provided nginx.conf, these services are served under a subpath corresponding to their name.
| Service | Addresses |
|---|---|
| Grafana | /grafana |
| Prometheus | /prometheus |
| Alloy | /alloy |