-
Notifications
You must be signed in to change notification settings - Fork 532
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Include distributed docker-compose example
Without this change, there is not an example of how a user might proceed with local testing and development using docker-compose. Here we copy the local docker-compose example and extend it to include the distributed configuration pieces necessary to get a functional example.
- Loading branch information
Showing
2 changed files
with
184 additions
and
0 deletions.
There are no files selected for viewing
122 changes: 122 additions & 0 deletions
122
example/docker-compose/local-distributed/docker-compose.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,122 @@ | ||
version: "3" | ||
services: | ||
|
||
distributor: | ||
image: tempo:latest | ||
command: "-target=distributor -config.file=/etc/tempo.yaml" | ||
volumes: | ||
- ./tempo-distributed.yaml:/etc/tempo.yaml | ||
- ./tempo-data:/tmp/tempo | ||
ports: | ||
- "14268" # jaeger ingest | ||
- "3200" # tempo | ||
- "7946" | ||
- "55680" # otlp grpc | ||
- "55681" # otlp http | ||
|
||
ingester-0: | ||
image: tempo:latest | ||
command: "-target=ingester -config.file=/etc/tempo.yaml" | ||
restart: always | ||
volumes: | ||
- ./tempo-distributed.yaml:/etc/tempo.yaml | ||
- ./tempo-data0:/tmp/tempo | ||
ports: | ||
- "14268" # jaeger ingest | ||
- "3200" # tempo | ||
- "7946" | ||
depends_on: | ||
- distributor | ||
|
||
ingester-1: | ||
image: tempo:latest | ||
command: "-target=ingester -config.file=/etc/tempo.yaml" | ||
restart: always | ||
volumes: | ||
- ./tempo-distributed.yaml:/etc/tempo.yaml | ||
- ./tempo-data1:/tmp/tempo | ||
ports: | ||
- "14268" # jaeger ingest | ||
- "3200" # tempo | ||
- "7946" | ||
depends_on: | ||
- distributor | ||
|
||
ingester-2: | ||
image: tempo:latest | ||
command: "-target=ingester -config.file=/etc/tempo.yaml" | ||
restart: always | ||
volumes: | ||
- ./tempo-distributed.yaml:/etc/tempo.yaml | ||
- ./tempo-data2:/tmp/tempo | ||
ports: | ||
- "14268" # jaeger ingest | ||
- "3200" # tempo | ||
- "7946" | ||
depends_on: | ||
- distributor | ||
|
||
tempo: | ||
image: tempo:latest | ||
command: "-target=query-frontend -config.file=/etc/tempo.yaml" | ||
volumes: | ||
- ./tempo-distributed.yaml:/etc/tempo.yaml | ||
- ./tempo-data:/tmp/tempo | ||
ports: | ||
- "14268" # jaeger ingest | ||
- "3200" # tempo | ||
- "7946" | ||
- "55680" # otlp grpc | ||
- "55681" # otlp http | ||
depends_on: | ||
- ingester-0 | ||
- ingester-1 | ||
- ingester-2 | ||
|
||
querier: | ||
image: tempo:latest | ||
command: "-target=querier -config.file=/etc/tempo.yaml" | ||
volumes: | ||
- ./tempo-distributed.yaml:/etc/tempo.yaml | ||
- ./tempo-data:/tmp/tempo | ||
ports: | ||
- "14268" # jaeger ingest | ||
- "3200" # tempo | ||
- "7946" | ||
- "55680" # otlp grpc | ||
- "55681" # otlp http | ||
depends_on: | ||
- ingester-0 | ||
- ingester-1 | ||
- ingester-2 | ||
|
||
synthetic-load-generator: | ||
image: omnition/synthetic-load-generator:1.0.25 | ||
volumes: | ||
- ../shared/load-generator.json:/etc/load-generator.json | ||
environment: | ||
- TOPOLOGY_FILE=/etc/load-generator.json | ||
- JAEGER_COLLECTOR_URL=http://distributor:14268 | ||
depends_on: | ||
- distributor | ||
- ingester-0 | ||
- ingester-1 | ||
|
||
prometheus: | ||
image: prom/prometheus:latest | ||
command: [ "--config.file=/etc/prometheus.yaml" ] | ||
volumes: | ||
- ../shared/prometheus.yaml:/etc/prometheus.yaml | ||
ports: | ||
- "9090:9090" | ||
|
||
grafana: | ||
image: grafana/grafana:7.5.7 | ||
volumes: | ||
- ../shared/grafana-datasources.yaml:/etc/grafana/provisioning/datasources/datasources.yaml | ||
environment: | ||
- GF_AUTH_ANONYMOUS_ENABLED=true | ||
- GF_AUTH_ANONYMOUS_ORG_ROLE=Admin | ||
- GF_AUTH_DISABLE_LOGIN_FORM=true | ||
ports: | ||
- "3000:3000" |
62 changes: 62 additions & 0 deletions
62
example/docker-compose/local-distributed/tempo-distributed.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
server: | ||
http_listen_port: 3200 | ||
|
||
distributor: | ||
receivers: # this configuration will listen on all ports and protocols that tempo is capable of. | ||
jaeger: # the receives all come from the OpenTelemetry collector. more configuration information can | ||
protocols: # be found there: https://github.com/open-telemetry/opentelemetry-collector/tree/main/receiver | ||
thrift_http: # | ||
grpc: # for a production deployment you should only enable the receivers you need! | ||
thrift_binary: | ||
thrift_compact: | ||
zipkin: | ||
otlp: | ||
protocols: | ||
http: | ||
grpc: | ||
opencensus: | ||
|
||
ingester: | ||
trace_idle_period: 10s # the length of time after a trace has not received spans to consider it complete and flush it | ||
max_block_bytes: 1_000_000 # cut the head block when it hits this size or ... | ||
max_block_duration: 5m # this much time passes | ||
lifecycler: | ||
ring: | ||
replication_factor: 3 | ||
|
||
memberlist: | ||
abort_if_cluster_join_fails: false | ||
bind_port: 7946 | ||
join_members: | ||
- ingester-0:7946 | ||
- ingester-1:7946 | ||
- ingester-2:7946 | ||
|
||
compactor: | ||
compaction: | ||
block_retention: 1h | ||
compacted_block_retention: 10m | ||
|
||
query_frontend: | ||
max_retries: 99 | ||
query_shards: 2 | ||
|
||
querier: | ||
frontend_worker: | ||
frontend_address: tempo:9095 | ||
|
||
storage: | ||
trace: | ||
backend: local # backend configuration to use | ||
block: | ||
bloom_filter_false_positive: .05 # bloom filter false positive rate. lower values create larger filters but fewer false positives | ||
index_downsample_bytes: 1000 # number of bytes per index record | ||
encoding: zstd # block encoding/compression. options: none, gzip, lz4-64k, lz4-256k, lz4-1M, lz4, snappy, zstd | ||
wal: | ||
path: /tmp/tempo/wal # where to store the the wal locally | ||
encoding: none # wal encoding/compression. options: none, gzip, lz4-64k, lz4-256k, lz4-1M, lz4, snappy, zstd | ||
local: | ||
path: /tmp/tempo/blocks | ||
pool: | ||
max_workers: 100 # worker pool determines the number of parallel requests to the object store backend | ||
queue_depth: 10000 |