Closed mzarnowski closed 9 months ago
Turns out that the user created this way is not a lingering one, thus the dns service is not running between ssh sessions. Once I added the following, it started working
- name: Enable lingering
# Required for dns service to keep running without active ssh session
command: "loginctl enable-linger {{ PODMAN_USER }}"
Feel free to close,if not actionable, although would be nice to include this requirement in some FAQ
Maybe something changed but I would expect the containers to die as well when you log out: https://github.com/containers/podman/blob/main/troubleshooting.md#17-rootless-containers-exit-once-the-user-session-exits
So yes I would say this behaviour is normal as you have to stay logged in our user lingering otherwise systemd juts kills the user processes.
Issue Description
I have created a dedicated user for running podman containers. My setup is as follows:
When I connect the gateway to internal-container's network using my default ansible user, then it all works OK. When I run the ubuntu containers and networks as a dedicated user, nslookup fails with:
The message varies depending on container, e.g on one based on 'alpine', it is:
I am running on RaspberryPi:
Linux hostname 6.1.0-rpi7-rpi-v8 #1 SMP PREEMPT Debian 1:6.1.63-1+rpt1 (2023-11-24) aarch64 GNU/Linux
Describe the results you received
When running as
ansible_user
I get:While running as
PODMAN_USER
I get:Describe the results you expected
I would like the
PODMAN_USER
's output to be like theansible_user
's :)I expected the gateway container to be able to nslookup the internal-container
podman info output
Podman in a container
No
Privileged Or Rootless
Rootless
Upstream Latest Release
No
Additional environment details
No response
Additional information
No response