Skip to content

docker-compose: map host.docker.internal to host-gateway - #10

Merged
canercidam merged 1 commit into
mainfrom
noot/linux-host-gateway
Sep 9, 2026
Merged

docker-compose: map host.docker.internal to host-gateway#10
canercidam merged 1 commit into
mainfrom
noot/linux-host-gateway

Conversation

@noot

@noot noot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • The docker-compose renderer now sets extra_hosts: ["host.docker.internal:host-gateway"] on each pod's network-owning (leader) container.
  • On a plain Linux docker engine host.docker.internal does not resolve inside containers unless extra_hosts says so; Docker Desktop provides it implicitly. Without the mapping every container reference to a host process times out: the beacon node cannot reach a host-run EL's authrpc, the relay cannot reach a host-run blocksim, and the chain sits at block 0.
  • Leaders only: docker rejects host mappings on a network_mode: service:<leader> peer, and the peers share the leader's network namespace anyway, so the one entry covers the pod.
  • host-gateway is the engine's special value for the host's gateway address (Linux engine 20.10+, also honoured by Docker Desktop), so this is a no-op where the name already resolved.

Test plan

  • deno lint, deno check renderers/docker-compose.ts
  • Verified on a Linux box: an L1 devnet with reth-rbuilder and a bidding gateway as host processes and the beacon/relay in containers. Before: beacon → EL authrpc timeouts, chain stuck at block 0. After: chain advances and the flow runs end to end (used for the JIT route devnet in rbuilder-prism decker/jit-router/).
  • CI green

On a Linux docker engine the name only resolves inside containers when
extra_hosts says so; docker desktop provides it implicitly. Without the
mapping every container reference to a host process (the beacon's
execution endpoint, the relay's blocksim) times out.
@noot
noot requested a review from canercidam September 9, 2026 03:20
@canercidam
canercidam merged commit 0e76a3c into main Sep 9, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants