-
Notifications
You must be signed in to change notification settings - Fork 46
OpenTelemetry
The setup comes with Grafana OTel-LGTM support, an all-in-one OpenTelemetry backend for development. The otel-lgtm container bundles an OpenTelemetry Collector, Loki (logs), Tempo (traces), Prometheus (metrics) and Grafana, so you can view telemetry emitted by your Totara sites.
The otel-lgtm container does not start by default. To start it run:
tup otel-lgtmIf you want it to start alongside your usual containers, add otel-lgtm to DEFAULT_CONTAINERS in your .env file.
The collector accepts OTLP over HTTP on port 4318:
- From your PHP containers use
http://otel-lgtm:4318 - From your host machine (e.g. scripts running outside Docker) use
http://localhost:4318
If your Totara version has a telemetry collector endpoint setting, point it at http://otel-lgtm:4318.
The PHP 8.4 and 8.5 containers also pass through the standard OTEL_* environment variables, so you can use OpenTelemetry's PHP auto-instrumentation. This is opt-in: uncomment the OTEL_* block in your .env file (see .env.dist) and recreate the PHP container.
Go to http://localhost:3000 to open the Grafana GUI.
- Logs: Explore > Loki, e.g. query
{service_name="totara"} - Traces: Explore > Tempo
- Metrics: Explore > Prometheus
Telemetry data is not persisted. Recreating the container gives you a clean slate.
Copyright (c) 2025 Totara Learning Solutions Limited
-
MailDev (for viewing emails)
-
OpenTelemetry (for viewing logs, traces and metrics)
-
Ngrok (for making your site publicly accessible)