services: benchmarkoor: image: ethpandaops/benchmarkoor:dev build: context: . dockerfile: Dockerfile args: VERSION: ${VERSION:-dev} COMMIT: ${COMMIT:-none} DATE: ${DATE:-unknown} # Required for dropping memory caches, ZFS/overlayfs datadir methods, etc. privileged: true # Share host PID namespace so nsenter can access /proc//ns/net # for dropping TCP connections before checkpoint-restore. pid: host environment: - BENCHMARKOOR_RUNNER_DROP_CACHES_PATH=/host_drop_caches - BENCHMARKOOR_RUNNER_CPU_SYSFS_PATH=/host_sys_cpu - BENCHMARKOOR_RUNNER_DIRECTORIES_TMP_DATADIR=${PWD}/tmp/data - BENCHMARKOOR_RUNNER_DIRECTORIES_TMP_CACHEDIR=${PWD}/tmp/cache - BENCHMARKOOR_RUNNER_BENCHMARK_RESULTS_OWNER=${USER_UID}:${USER_GID} volumes: # The docker socket is required to interact with docker containers - /var/run/docker.sock:/var/run/docker.sock:ro # The podman socket is required when using container_runtime: podman - /run/podman/podman.sock:/run/podman/podman.sock # Podman container storage, required for checkpoint-restore - /var/lib/containers:/var/lib/containers:rshared # The cgroups path is recommended when on Linux systems to fetch system metrics - /sys/fs/cgroup:/sys/fs/cgroup:ro # Required for dropping memory caches between tests (config.yaml#client.config.drop_memory_caches) - /proc/sys/vm/drop_caches:/host_drop_caches # Required for CPU frequency control (config.yaml#client.config.resource_limits.cpu_freq) - /sys/devices/system/cpu:/host_sys_cpu # Config file - ./${BENCHMARKOOR_CONFIG:-config.example.docker.yaml}:/app/config.yaml:ro # Temp directory (For fetching temporary files and node data dirs) # rshared propagation ensures overlay mounts are visible to sibling containers - type: bind source: ${PWD}/tmp target: ${PWD}/tmp bind: propagation: rshared # For ZFS datadir methods, mount your ZFS data path with rshared propagation: #- type: bind # source: /data-zfs-2 # target: /data-zfs-2 # bind: # propagation: rshared # Results directory - ./results:/app/results working_dir: /app command: ["run", "--config", "/app/config.yaml"] network_mode: host api: image: ethpandaops/benchmarkoor:dev build: context: . dockerfile: Dockerfile volumes: # Config file - ./${BENCHMARKOOR_CONFIG:-config.example.docker.yaml}:/app/config.yaml:ro # Data directory for SQLite DB - ./data:/app/data working_dir: /app command: ["api", "--config", "/app/config.yaml"] ports: - "${API_PORT:-9090}:9090" ui: image: ethpandaops/benchmarkoor-ui:dev build: context: . dockerfile: Dockerfile.ui args: APP_VERSION: ${APP_VERSION:-dev} ports: - "${UI_PORT:-8080}:80" volumes: - ./results:/usr/share/nginx/html/results:ro # Override runtime config to point UI at the API service - ./ui/public/config.docker.json:/usr/share/nginx/html/config.json:ro depends_on: - benchmarkoor