buildah icon indicating copy to clipboard operation
buildah copied to clipboard

No way to expose UDP port

Open dilyanpalauzov opened this issue 1 year ago • 6 comments

Docker’s file EXPOSE https://docs.docker.com/engine/reference/builder/#expose lets explicitly specify that the protocol is UDP.

Containerfile - https://github.com/containers/common/blob/main/docs/Containerfile.5.md and buildah config --port do not allow for specifying UDP, or at least, the documentation does not say it is possible to expose an UDP port.

Concerning EXPOSE https://github.com/containers/common/blob/main/docs/Containerfile.5.md says:

The EXPOSE instruction informs the container engine that the container listens on the specified network ports at runtime. The container engine uses this information to interconnect containers using links and to set up port redirection on the host system.

To be honest I do not understand how is the EXPOSEd information used by the container engine, apart from letting podman assigned the internal ports to random outside ports.

dilyanpalauzov avatar Jan 04 '23 18:01 dilyanpalauzov

A friendly reminder that this issue had no activity for 30 days.

github-actions[bot] avatar Feb 04 '23 00:02 github-actions[bot]

@flouthoc @vrothberg PTAL

rhatdan avatar Feb 06 '23 22:02 rhatdan

A friendly reminder that this issue had no activity for 30 days.

github-actions[bot] avatar Mar 10 '23 00:03 github-actions[bot]

With buildah -1.29.1-2, udp port does get exposed

[root@atomic-test tmp]# buildah config --port 53/udp $container [root@atomic-test tmp]# buildah commit --format docker $container port:latest [root@atomic-test tmp]# buildah commit --format docker $container port:latest

[root@atomic-test tmp]# podman create -it -P port:latest 56545611f432ad5557e3ef30204e835403a0f51460b108fc2cf32a27fdb06d28 [root@atomic-test tmp]# podman start 56545611f432ad5557e3ef30204e835403a0f51460b108fc2cf32a27fdb06d28 56545611f432ad5557e3ef30204e835403a0f51460b108fc2cf32a27fdb06d28 [root@atomic-test tmp]# podman port -l 53/udp -> 0.0.0.0:5714

ranjithrajaram avatar Jun 05 '23 10:06 ranjithrajaram

This is not yet implemented :)

flouthoc avatar Jun 05 '23 10:06 flouthoc

A friendly reminder that this issue had no activity for 30 days.

github-actions[bot] avatar Jul 06 '23 00:07 github-actions[bot]