mirror of
https://github.com/hyperdxio/hyperdx
synced 2026-04-21 13:37:15 +00:00
Gets us closer to a staging instance of json <img width="216" height="174" alt="image" src="https://github.com/user-attachments/assets/b5cc3cf8-aef0-4ba4-9e9a-8c1d4fad5451" /> Co-authored-by: Warren <5959690+wrn14897@users.noreply.github.com>
139 lines
5 KiB
YAML
139 lines
5 KiB
YAML
name: hdx-oss-dev
|
|
x-hyperdx-logging: &hyperdx-logging
|
|
driver: fluentd
|
|
options:
|
|
fluentd-address: tcp://localhost:24225
|
|
fluentd-async: 'true'
|
|
labels: 'service.name'
|
|
services:
|
|
db:
|
|
logging: *hyperdx-logging
|
|
labels:
|
|
service.name: 'hdx-oss-dev-db'
|
|
image: mongo:5.0.14-focal
|
|
volumes:
|
|
- .volumes/db_dev:/data/db
|
|
ports:
|
|
- 27017:27017
|
|
networks:
|
|
- internal
|
|
depends_on:
|
|
- otel-collector
|
|
otel-collector:
|
|
# image: otel/opentelemetry-collector-contrib:0.120.0
|
|
build:
|
|
context: ./docker/otel-collector
|
|
target: dev
|
|
environment:
|
|
CLICKHOUSE_ENDPOINT: 'tcp://ch-server:9000?dial_timeout=10s'
|
|
CLICKHOUSE_PROMETHEUS_METRICS_ENDPOINT: 'ch-server:9363'
|
|
HYPERDX_OTEL_EXPORTER_CLICKHOUSE_DATABASE: ${HYPERDX_OTEL_EXPORTER_CLICKHOUSE_DATABASE}
|
|
HYPERDX_API_KEY: ${HYPERDX_API_KEY}
|
|
HYPERDX_LOG_LEVEL: ${HYPERDX_LOG_LEVEL}
|
|
OPAMP_SERVER_URL: 'http://host.docker.internal:${HYPERDX_OPAMP_PORT}'
|
|
CUSTOM_OTELCOL_CONFIG_FILE: '/etc/otelcol-contrib/custom.config.yaml'
|
|
# Uncomment to enable stdout logging for the OTel collector
|
|
OTEL_SUPERVISOR_LOGS: 'true'
|
|
volumes:
|
|
- ./docker/otel-collector/config.yaml:/etc/otelcol-contrib/config.yaml
|
|
- ./docker/otel-collector/supervisor_docker.yaml.tmpl:/etc/otel/supervisor.yaml.tmpl
|
|
# Add a custom config file
|
|
- ./docker/otel-collector/custom.config.yaml:/etc/otelcol-contrib/custom.config.yaml
|
|
ports:
|
|
- '13133:13133' # health_check extension
|
|
- '24225:24225' # fluentd receiver
|
|
- '4317:4317' # OTLP gRPC receiver
|
|
- '4318:4318' # OTLP http receiver
|
|
- '8888:8888' # metrics extension
|
|
restart: always
|
|
networks:
|
|
- internal
|
|
depends_on:
|
|
ch-server:
|
|
condition: service_healthy
|
|
otel-collector-json:
|
|
# image: otel/opentelemetry-collector-contrib:0.120.0
|
|
build:
|
|
context: ./docker/otel-collector
|
|
target: dev
|
|
environment:
|
|
CLICKHOUSE_ENDPOINT: 'tcp://ch-server:9000?dial_timeout=10s'
|
|
CLICKHOUSE_PROMETHEUS_METRICS_ENDPOINT: 'ch-server:9363'
|
|
HYPERDX_OTEL_EXPORTER_CLICKHOUSE_DATABASE: 'otel_json'
|
|
HYPERDX_API_KEY: ${HYPERDX_API_KEY}
|
|
HYPERDX_LOG_LEVEL: ${HYPERDX_LOG_LEVEL}
|
|
OPAMP_SERVER_URL: 'http://host.docker.internal:${HYPERDX_OPAMP_PORT}'
|
|
CUSTOM_OTELCOL_CONFIG_FILE: '/etc/otelcol-contrib/custom.config.yaml'
|
|
# Uncomment to enable stdout logging for the OTel collector
|
|
OTEL_SUPERVISOR_LOGS: 'true'
|
|
# Uncomment to enable JSON schema in ClickHouse
|
|
# Be sure to also set BETA_CH_OTEL_JSON_SCHEMA_ENABLED to 'true' in ch-server
|
|
OTEL_AGENT_FEATURE_GATE_ARG: '--feature-gates=clickhouse.json'
|
|
volumes:
|
|
- ./docker/otel-collector/config.yaml:/etc/otelcol-contrib/config.yaml
|
|
- ./docker/otel-collector/supervisor_docker.yaml.tmpl:/etc/otel/supervisor.yaml.tmpl
|
|
# Add a custom config file
|
|
- ./docker/otel-collector/dev.json.config.yaml:/etc/otelcol-contrib/custom.config.yaml
|
|
ports:
|
|
- '14318:4318' # OTLP http receiver
|
|
restart: always
|
|
networks:
|
|
- internal
|
|
depends_on:
|
|
ch-server:
|
|
condition: service_healthy
|
|
ch-server:
|
|
image: clickhouse/clickhouse-server:25.7-alpine
|
|
ports:
|
|
- 8123:8123 # http api
|
|
- 9000:9000 # native
|
|
environment:
|
|
# default settings
|
|
CLICKHOUSE_DEFAULT_ACCESS_MANAGEMENT: 1
|
|
HYPERDX_OTEL_EXPORTER_CLICKHOUSE_DATABASE: ${HYPERDX_OTEL_EXPORTER_CLICKHOUSE_DATABASE}
|
|
# Set to 'true' to allow for proper OTel JSON Schema creation
|
|
# Be sure to also set the OTEL_AGENT_FEATURE_GATE_ARG env in otel-collector
|
|
# BETA_CH_OTEL_JSON_SCHEMA_ENABLED: 'true'
|
|
volumes:
|
|
- ./docker/clickhouse/local/config.xml:/etc/clickhouse-server/config.xml
|
|
- ./docker/clickhouse/local/users.xml:/etc/clickhouse-server/users.xml
|
|
- ./docker/clickhouse/local/init-db.sh:/docker-entrypoint-initdb.d/init-db.sh
|
|
- .volumes/ch_data_dev:/var/lib/clickhouse
|
|
- .volumes/ch_logs_dev:/var/log/clickhouse-server
|
|
restart: on-failure
|
|
networks:
|
|
- internal
|
|
healthcheck:
|
|
# "clickhouse", "client", "-u ${CLICKHOUSE_USER}", "--password ${CLICKHOUSE_PASSWORD}", "-q 'SELECT 1'"
|
|
test:
|
|
wget -O /dev/null --no-verbose --tries=1 http://127.0.0.1:8123/ping ||
|
|
exit 1
|
|
interval: 1s
|
|
timeout: 1s
|
|
retries: 60
|
|
|
|
# nginx:
|
|
# image: nginx:alpine
|
|
# ports:
|
|
# - '4040:4040'
|
|
# volumes:
|
|
# - ./proxy/nginx/nginx.conf.template:/etc/nginx/templates/default.conf.template:ro
|
|
# environment:
|
|
# HYPERDX_BASE_PATH: ${HYPERDX_BASE_PATH:-/}
|
|
# network_mode: host
|
|
# restart: always
|
|
|
|
# traefik:
|
|
# image: traefik:latest
|
|
# ports:
|
|
# - '4040:4040'
|
|
# volumes:
|
|
# - ./proxy/traefik/traefik.yml:/etc/traefik/traefik.yml:ro
|
|
# - ./proxy/traefik/config.yml:/etc/traefik/dynamic/config.yml:ro
|
|
# environment:
|
|
# HYPERDX_BASE_PATH: ${HYPERDX_BASE_PATH:-/}
|
|
# network_mode: host
|
|
# restart: always
|
|
|
|
networks:
|
|
internal:
|