-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompose.python.dev.yaml
More file actions
80 lines (76 loc) · 2.46 KB
/
Copy pathcompose.python.dev.yaml
File metadata and controls
80 lines (76 loc) · 2.46 KB
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
75
76
77
78
79
80
# docker-compose.base.yml
services:
python-app:
build:
context: .
dockerfile: Dockerfile
target: python-dev
args:
HTTP_PROXY: ${HTTP_PROXY}
HTTPS_PROXY: ${HTTPS_PROXY}
NO_PROXY: ${NO_PROXY}
PIP_INDEX_URL: ${PIP_INDEX_URL:-https://pypi.org/simple}
CONTAINER_REGISTRY_URL: ${CONTAINER_REGISTRY_URL:-localhost}
volumes:
- ./src:/app/src
ports:
- 8000:8000
environment:
OTEL_SERVICE_NAME: "fastapi-app"
OTEL_SERVICE_INSTANCE_ID: "fastapi-instance-1"
OTEL_EXPORTER_OTLP_TRACES_ENDPOINT: "http://collector:4318/v1/traces"
OTEL_EXPORTER_OTLP_METRICS_ENDPOINT: "http://collector:4318/v1/metrics"
OTEL_EXPORTER_OTLP_LOGS_ENDPOINT: "http://collector:4318/v1/logs"
OTEL_EXPORTER_OTLP_ENDPOINT: "http://collector:4318"
# Proxy settings
HTTP_PROXY: ${HTTP_PROXY}
HTTPS_PROXY: ${HTTPS_PROXY}
NO_PROXY: ${NO_PROXY}
# Explicitly tell uv to use the proxy
UV_HTTP_PROXY: ${HTTPS_PROXY:-$HTTP_PROXY}
UV_HTTPS_PROXY: ${HTTPS_PROXY}
UV_NO_PROXY: ${NO_PROXY}
depends_on:
- collector
networks:
- observe-network
collector:
container_name: collector
image: ${CONTAINER_REGISTRY_URL:-docker.io}/otel/opentelemetry-collector-contrib:0.127.0
volumes:
- ./config/otel/collector-config.yaml:/etc/otelcol-contrib/config.yaml
command: ["--config", "/etc/otelcol-contrib/config.yaml"]
expose:
- 4318 # OTLP http receiver
ports:
- 13133:13133 # health_check extension
- 4318:4318 # OTLP http receiver
environment:
OPENOBSERVE_ENDPOINT: "http://openobserve:5080/api/default"
OPENOBSERVE_AUTH_KEY: "cm9vdEBleGFtcGxlLmNvbTpDb21wbGV4cGFzcyMxMjM=" # echo -n 'EMAIL:PASSWORD' | base64
# Prevent proxying internal calls:
NO_PROXY: "openobserve,localhost,127.0.0.1,::1"
# If your environment injects proxies, explicitly unset them for this service:
HTTP_PROXY: ""
HTTPS_PROXY: ""
networks:
- observe-network
openobserve:
container_name: openobserve
image: ${CONTAINER_REGISTRY_URL:-docker.io}/openobserve/openobserve:v0.15.0-rc1
restart: unless-stopped
environment:
ZO_ROOT_USER_EMAIL: "root@example.com"
ZO_ROOT_USER_PASSWORD: "Complexpass#123"
volumes:
- data:/data
ports:
- 5080:5080
networks:
- observe-network
depends_on:
- collector
networks:
observe-network:
volumes:
data: