docker for mac beta and docker:start with wait/tcp/ports incorrectly waits on container port
See original GitHub issueRunning a maven project that uses the wait/tcp/ports functionality to wait for the container to listen on a specific port:
Observed results:
With docker-machine, the logs output
[INFO] DOCKER> [mysql:5.7] "db": Start container 5289bed0ef48
[INFO] DOCKER> [mysql:5.7] "db": Waiting for exposed ports [32780] on remote host (192.168.251.207), since they are not directly accessible.
With docker for mac beta:
[INFO] DOCKER> [mysql:5.7] "db": Start container d79b36323981
[INFO] DOCKER> [mysql:5.7] "db": Waiting for ports [3306] directly on container with IP (172.17.0.2).
[ERROR] DOCKER> [mysql:5.7] "db": Timeout after 60405 ms while waiting on tcp port '[/172.17.0.2:3306]'
[ERROR] DOCKER> Error occurred during container startup, shutting down...
Expected results:
Build should pass with either docker-machine or docker for mac
Preliminary analysis:
Something seems to be going wrong in the detection of whether the container is directly accessible.
Issue Analytics
- State:
- Created 7 years ago
- Comments:23
Top Results From Across the Web
error invoking remote method 'docker-start-container' ports are ...
Docker. Error: Cannot start container: port has already been allocated ... for mac beta and docker:start with wait/tcp/ports incorrectly waits on container ......
Read more >Frequently asked questions - Docker Documentation
Compose stop attempts to stop a container by sending a SIGTERM . It then waits for a default timeout of 10 seconds. After...
Read more >docker port - Docker Documentation
docker port : List port mappings or a specific mapping for the container.
Read more >Docker Engine release notes - Docker Documentation
This release of Docker Engine contains some bug-fixes and packaging changes, updates to the docker scan and docker buildx commands, an updated version...
Read more >Docker Engine release notes
Wasm is a fast, light alternative to Linux containers – try it out today with the Docker+Wasm Beta. ✕. Docker Docs.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@ol2ka , sure, just remove these tags
I for one haven’t had to use another work around, but reviewing the documentation. You could configure a health check that is more robust than just establishing an ephemeral connection and wait on that with the
healthy
wait: https://dmp.fabric8.io/#build-healthcheckHaven’t looked at this, just tossing it out as an idea.