Skip to content

Commit

Permalink
adding app6 in the docker compose
Browse files Browse the repository at this point in the history
  • Loading branch information
biandratti committed Jun 16, 2024
1 parent b4e14ab commit 4d2e8cb
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 3 deletions.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,14 @@ curl -i --header "context-id: mycontextid" localhost:9001/api/v1/trace
---
### Example 2: OpenTelemetry agent

* app3 and app4 are Play Framework applications, while app5 is Zio HTTP
* app3 and app4 are Play Framework applications, while app5 is Zio HTTP, and app6 is Http4s
* All apps use OpenTelemetry for monitoring.
* OpenTelemetry agent sends tracing and metrics to OTEL.
* Prometheus:
* http://localhost:9093
* http://localhost:9094
* http://localhost:9095
* http://localhost:9096
* jaeger: http://localhost:16686

```
Expand Down
2 changes: 2 additions & 0 deletions docker/build-apps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,5 @@ echo "building app4 **************"
sbt app4/docker:publishLocal
echo "building app5 **************"
sbt app5/docker:publishLocal
echo "building app6 **************"
sbt app6/docker:publishLocal
23 changes: 21 additions & 2 deletions docker/opentelemetry/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,25 @@ services:
depends_on:
- jaeger

app6:
image: app6
hostname: app6
restart: always
environment:
- OTEL_SERVICE_NAME=app6
- OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=http://otel-collector:4317
- OTEL_EXPORTER_OTLP_PROTOCOL=grpc
- OTEL_METRICS_EXPORTER=prometheus
- OTEL_EXPORTER_PROMETHEUS_PORT=9096
- OTEL_EXPORTER_PROMETHEUS_HOST=0.0.0.0
networks:
- tracenet
ports:
- "9006:9006"
- "9096:9096"
depends_on:
- otel-collector

app5:
image: app5
hostname: app5
Expand Down Expand Up @@ -78,13 +97,13 @@ services:
- OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=http://otel-collector:4317
- OTEL_EXPORTER_OTLP_PROTOCOL=grpc
- OTEL_METRICS_EXPORTER=prometheus
- OTEL_EXPORTER_PROMETHEUS_PORT=9094
- OTEL_EXPORTER_PROMETHEUS_PORT=9093
- OTEL_EXPORTER_PROMETHEUS_HOST=0.0.0.0
networks:
- tracenet
ports:
- "9003:9003"
- "9093:9094"
- "9093:9093"
depends_on:
- app4
- app5
Expand Down

0 comments on commit 4d2e8cb

Please sign in to comment.