You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a DinD (Docker-in-Docker) sidecar is configured at the workflow scope (e.g., DOCKER_HOST=tcp://localhost:2375), AWF-compiled workflows fail during container startup with:
[INFO] Set DOCKER_API_VERSION=1.54 (server current)
Error: Port 80 is not exposed from the container
Error: Add port mapping: -p <host_port>:80
When DOCKER_HOST points to a DinD daemon, the AWF docker compose commands run against the DinD daemon. The DinD daemon's port mapping behavior differs from the default Docker socket (/var/run/docker.sock): published ports are only accessible within the DinD network, not from the host runner. The AWF-generated docker-compose.yml does not expose port 80 as a host-mapped port (it's only used internally in the overlay network 172.30.0.0/24), but the DinD networking layer raises this error when attempting to set up port forwarding for its internal routing.
The getLocalDockerEnv() function in src/docker-manager.ts (line 69-84) clones process.env and normalizes DOCKER_HOST, but does not detect or adapt for DinD-mode Docker daemons.
Proposed Solution
Detect DinD mode in src/docker-manager.ts: In getLocalDockerEnv(), when DOCKER_HOST is set to a TCP address (e.g., tcp://localhost:2375), set a dind flag on the config.
Adapt network configuration for DinD: When in DinD mode, modify the generated docker-compose.yml in generateDockerCompose() (or src/docker-manager.ts) to:
Use network_mode: host for containers that need host-accessible ports, or
Add explicit port mappings, or
Use a DinD-compatible bridge network configuration.
Add documentation: In docs/environment.md, document the DinD compatibility flag and any required workflow configuration when using DinD sidecars alongside AWF.
Integration test: Add a test case that validates AWF container startup when DOCKER_HOST is set to a TCP address.
Both issues describe the same core problem: DOCKER_HOST set to a TCP address (DinD sidecar) causes AWF container startup failures due to network/port mapping incompatibilities in docker-manager.ts.
If one of these addresses your concern, please consider closing this issue as a duplicate. Otherwise, feel free to clarify how your issue differs (e.g., a new error symptom or a regression after a fix was applied)!
This is an automated message from the issue duplication detector.
Activity
github-actions commentedon Apr 16, 2026
👋 Hello! I noticed this issue might be related to existing issues:
DOCKER_HOSTpointing to a DinD daemon breaking AWFBoth issues describe the same core problem:
DOCKER_HOSTset to a TCP address (DinD sidecar) causes AWF container startup failures due to network/port mapping incompatibilities indocker-manager.ts.If one of these addresses your concern, please consider closing this issue as a duplicate. Otherwise, feel free to clarify how your issue differs (e.g., a new error symptom or a regression after a fix was applied)!
This is an automated message from the issue duplication detector.
lpcox commentedon Apr 16, 2026
Fixed by #1943 (handle workflow-scope DinD DOCKER_HOST=tcp:// without failing AWF startup). Merged to main.