services: postgres: image: postgres:16.4 shm_size: 256mb command: | postgres -c shared_preload_libraries=pg_stat_statements -c pg_stat_statements.track=all -c max_connections=200 -c shared_buffers=256MB -c effective_cache_size=8GB -c work_mem=16MB -c maintenance_work_mem=128MB -c min_wal_size=128MB -c max_wal_size=2GB -c checkpoint_completion_target=0.9 -c wal_buffers=16MB -c default_statistics_target=100 ports: - 5432:5432 volumes: - postgres-volume:/var/lib/postgresql/data environment: - POSTGRES_DB=postgres - POSTGRES_USER=postgres - POSTGRES_PASSWORD=postgres grafana: image: grafana/grafana:11.1.4 shm_size: 256mb ports: - 3000:3000 extra_hosts: - "host.docker.internal:host-gateway" volumes: - grafana-volume:/var/lib/grafana - ./deploy/grafana-ds.yaml:/etc/grafana/provisioning/datasources/datasources.yaml prometheus: image: prom/prometheus:v2.54.0 shm_size: 256mb user: root ports: - 9090:9090 extra_hosts: - "host.docker.internal:host-gateway" volumes: - prometheus-volume:/etc/prometheus - ./deploy/prometheus.yml:/etc/prometheus/prometheus.yml node_exporter: image: quay.io/prometheus/node-exporter:latest command: - '--path.rootfs=/host' ports: - 9100:9100 extra_hosts: - "host.docker.internal:host-gateway" pid: host volumes: - '/:/host:ro,rslave' otel-collector: image: otel/opentelemetry-collector-contrib:0.108.0 volumes: - ./deploy/otel-collector.yaml:/etc/otelcol-contrib/config.yaml ports: - 8888:8888 # Prometheus metrics exposed by the Collector - 8889:8889 # Prometheus exporter metrics - 13133:13133 # health_check extension # - 4317:4317 # OTLP gRPC receiver - 4318:4318 # OTLP http receiver tempo-init: image: &tempoImage grafana/tempo:2.3.1 user: root entrypoint: - "chown" - "10001:10001" - "/var/tempo" volumes: - tempo-volume:/var/tempo tempo: image: *tempoImage command: [ "-config.file=/etc/tempo.yaml" ] volumes: - ./deploy/tempo.yaml:/etc/tempo.yaml - tempo-volume:/var/tempo depends_on: - tempo-init # backend: # build: . # # dockerfile: ./dockerfile # volumes: # - ./:/app # ports: # - 8080:8080 volumes: postgres-volume: grafana-volume: tempo-volume: prometheus-volume: