podman run fails without /etc/hosts #12667
Labels
kind/bug
Categorizes issue or PR as related to a bug.
locked - please file new issue/PR
Assist humans wanting to comment on an old issue or PR with locked comments.
/kind bug
Description
Starting a podman container (as root/system or as user, same issue) fails if the host does not have an
/etc/hosts
file. Having one is not really necessary --nss-systemd
auto-resolves things like "localhost", "localhost6" and the host's own hostname automatically, so in most cases /etc/hosts is just an obsolete boilerplate file these days.Steps to reproduce the issue:
sudo mv /etc/hosts{,.disabled}
podman run -it --rm docker.io/busybox
Describe the results you received:
This is a bit pointless -- the container's /etc/hosts is generated by podman anyway.
Describe the results you expected:
Container starts up.
Fixing this can be done by
sudo touch /etc/hosts
, i. e. just having an empty file.Output of
podman version
:Output of
podman info --debug
:Package info (e.g. output of
rpm -q podman
orapt list podman
):Have you tested with the latest version of Podman and have you checked the Podman Troubleshooting Guide? (https://github.com/containers/podman/blob/master/troubleshooting.md)
No, but even Rawhide does not have a newer version -- there is no newer release.
The text was updated successfully, but these errors were encountered: