Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for reaching containers using host networking on Podman #9190

Merged
merged 4 commits into from Jul 19, 2022

Conversation

freundTech
Copy link
Contributor

@freundTech freundTech commented Jul 14, 2022

What does this PR do?

This PR adds support for reaching containers using host networking on systems using podman by allowing traefik to correctly detect the podman gateway.

On docker traefik detects the gateway by looking up host.docker.internal. Podman doesn't support the host.docker.internal domain, but added support for host.containers.internal in containers/podman#9972 instead.
Without this PR podman users would have to manually set host.docker.internal using add-host/extra_hosts.

Motivation

I'm using traefik on a server running podman and ran into this issue.

Related to #5730

More

  • Added/updated tests
  • Added/updated documentation

Additional Notes

It would also be possible so solve this using a loop, but because there are only two domains I think that it is more readable without one. Should more domains be needed in the future I would recommend using a loop here.

Copy link
Member

@kevinpollet kevinpollet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 👍

@kevinpollet kevinpollet changed the title Add support for reaching containers using host networking on podman Add support for reaching containers using host networking on Podman Jul 19, 2022
Copy link
Member

@rtribotte rtribotte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 👍

@rtribotte rtribotte mentioned this pull request Jul 19, 2022
@traefiker traefiker merged commit f85f3b6 into traefik:master Jul 19, 2022
v2 automation moved this from To review to Done Jul 19, 2022
@freundTech freundTech deleted the featue-podman-gateway branch January 22, 2023 22:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
No open projects
v2
Done
Development

Successfully merging this pull request may close these issues.

None yet

6 participants