mirror of
https://github.com/docker/cli.git
synced 2026-01-13 18:22:35 +03:00
When a container is created if "--network" is set to "host" all the ports in the container are bound to the host. Thus, adding "-p" or "--publish" to the command-line is meaningless. Unlike "docker run" and "docker create", "docker service create" sends an error message when network mode is host and port bindings are given This patch however suggests to send a warning message to the client when such a case occurs. The warning message is added to "warnings" which are returned from "verifyPlatformContainerSettings". Signed-off-by: Boaz Shuster <ripcurld.github@gmail.com> Upstream-commit: 6e78fdb790d2e1dbf95a1733cab9395b1b936622 Component: engine