This project provides a containerized setup for running Grafana Tempo with S3-compatible storage using Docker and Docker Compose. It is designed for easy local development and deployment, leveraging environment variables for secure configuration.
- Grafana Tempo: Distributed tracing backend.
- S3 Storage: Traces are stored in an S3-compatible bucket.
- Dockerized: Easy to run and configure using Docker and Docker Compose.
- Environment-based Configuration: Secrets and settings are managed via environment variables.
graph TD
Client[Client / Application]
OTLP[OTLP Exporter]
Tempo[Grafana Tempo]
S3[S3-Compatible Storage]
Client -- Traces --> OTLP
OTLP -- HTTP/GRPC (4317/4318) --> Tempo
Tempo -- S3 API --> S3
- Client: Your application or service instrumented with OpenTelemetry.
- OTLP Exporter: Sends trace data to Tempo using OTLP over HTTP or gRPC.
- Tempo: Receives, processes, and stores traces.
- S3 Storage: Stores trace data for long-term retention.
docker-compose.yml: Orchestrates the Tempo service and injects environment variables for S3 configuration.Dockerfile: Builds a custom Tempo image with the provided configuration.tempo.yaml: Main configuration file for Tempo, including S3 backend settings..env.example: Template for required environment variables..env: (Should not be committed) Actual secrets and configuration values (excluded by.gitignore).
-
Copy and configure environment variables:
cp .env.example .env # Edit .env and fill in your S3 credentials and settings -
Build and start the service:
docker-compose up --build
-
Access Tempo:
- Tempo HTTP server: http://localhost:3200
- OTLP gRPC:
localhost:4317 - OTLP HTTP:
localhost:4318
See .env.example for all required variables:
S3_BUCKET_NAMES3_REGIONS3_ENDPOINTS3_ACCESS_KEY_IDS3_SECRET_ACCESS_KEY
- Never commit your
.envfile. It is excluded by.gitignore. - Use
.env.exampleas a template for sharing configuration requirements.