-
Notifications
You must be signed in to change notification settings - Fork 28
/
Copy pathdocker-compose.yaml
74 lines (69 loc) · 2.22 KB
/
docker-compose.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
# Riverbed-Community-Toolkit
# 105-opentelemetry-go-app
# version: 24.10.4
#
# Simple 2 tier Go application using the OpenTelemetry SDK. Capable of showing distributed traces
# using the Otlp, Jaeger, or Zipkin formats.
#
# Reference:
# * https://hub.docker.com/r/aternity/apm-collector
# * https://www.riverbed.com/products/application-performance-monitoring
#
# Usage:
# docker-compose up
#
# Example in Unix
# RIVERBED_APM_SAAS_SERVER_HOST="agents.apm.myaccount.aternity.com" RIVERBED_APM_CUSTOMER_ID="12341234-12341234-13241234" docker-compose up
#
# Example PowerShell
# $env:RIVERBED_APM_SAAS_SERVER_HOST="agents.apm.myaccount.aternity.com"
# $env:RIVERBED_APM_CUSTOMER_ID="12341234-12341234-13241234"
# docker-compose up
services:
riverbed-apm-collector:
image: aternity/apm-collector:latest
container_name: riverbed-apm-collector
environment:
- SERVER_URL=wss://${RIVERBED_APM_SAAS_SERVER_HOST}/?RPM_AGENT_CUSTOMER_ID=${RIVERBED_APM_CUSTOMER_ID}
service105-go-backend:
depends_on:
- riverbed-apm-collector
command: backend
container_name: opentelemetry-go-backend
environment:
OTEL_SERVICE_NAME: service105-go-backend
OTEL_TRACES_EXPORTER: otlp # otlp, jaeger, zipkin, file
ADD_CONSOLE_EXPORTER: "off" # "on", "off"
RIVERBED_APM_COLLECTOR_SERVICE_HOST: riverbed-apm-collector
build:
context: .
dockerfile: Dockerfile
service105-go-frontend:
depends_on:
- service105-go-backend
command: frontend
container_name: opentelemetry-go-frontend
environment:
OTEL_SERVICE_NAME: service105-go-frontend
OTEL_TRACES_EXPORTER: otlp # otlp, jaeger, zipkin, file
ADD_CONSOLE_EXPORTER: "off" # "on", "off"
RIVERBED_APM_COLLECTOR_SERVICE_HOST: riverbed-apm-collector
BACKEND_SERVICE_HOST: opentelemetry-go-backend
ports:
- 8081:8081
build:
context: .
dockerfile: Dockerfile
service105-traffic-generator:
depends_on:
- service105-go-frontend
image: alpine/curl:latest
container_name: traffic-generator
command: >
/bin/sh -c "
sleep 5;
while :; do
curl http://opentelemetry-go-frontend:8081/ > /dev/null 2>&1;
sleep 5;
done
"