Skip to content

Commit cb649c9

Browse files
committed
Update shared.bash
1 parent 6f4b952 commit cb649c9

1 file changed

Lines changed: 4 additions & 6 deletions

File tree

lib/shared.bash

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -324,15 +324,13 @@ function run_docker_compose() {
324324
plugin_prompt_and_run "${command[@]}" "$@"
325325
)
326326
else
327-
# Enable docker-compose OTEL tracing explicitly
328-
# Docker Compose requires COMPOSE_EXPERIMENTAL_OTEL=1 to create traces
329-
echo "DEBUG: Docker Compose OTEL tracing enabled"
327+
# Let Docker Compose auto-detect OTEL configuration from environment variables
328+
# Setting OTEL_SERVICE_NAME will make compose spans appear under buildkite-agent service
329+
echo "DEBUG: Docker Compose OTEL auto-detection (not setting COMPOSE_EXPERIMENTAL_OTEL)"
330330
echo "DEBUG: TRACEPARENT=${TRACEPARENT:-NOT SET}"
331331
echo "DEBUG: OTEL_SERVICE_NAME=${OTEL_SERVICE_NAME:-NOT SET}"
332-
echo "DEBUG: OTEL_RESOURCE_ATTRIBUTES=${OTEL_RESOURCE_ATTRIBUTES:-NOT SET}"
333332
echo "DEBUG: OTEL_EXPORTER_OTLP_ENDPOINT=${OTEL_EXPORTER_OTLP_ENDPOINT:-NOT SET}"
334-
echo "DEBUG: Setting COMPOSE_EXPERIMENTAL_OTEL=1"
335-
export COMPOSE_EXPERIMENTAL_OTEL=1
333+
echo "DEBUG: OTEL_EXPORTER_OTLP_HEADERS=${OTEL_EXPORTER_OTLP_HEADERS:-NOT SET}"
336334
plugin_prompt_and_run "${command[@]}" "$@"
337335
fi
338336
}

0 commit comments

Comments
 (0)