On Fri, 2020-08-14 at 11:02 +0200, Ludwig Nussel wrote:
Richard Brown wrote:
[...] This implies that there is some kind of race condition with the container starting before the hosts /etc/resolv.conf is being set properly.
I suspect this is probably a side effect of wicked being a little..inconsistant with how it informs systemd of it's readiness, but whatever the root cause, I find myself wondering if "After=network- online.target" is the best good practice for containers anyway.
Wicked is a bit fubar¹. However, even if it was fixed, relying on network-online.target would still be a hack. Also copying resolv.conf as one shot operation seems old school. A better way would be to use eg systemd-resolved or dnsmasq on 127.0.0.1 and make the containers talk to that. That way containers could start up ASAP during boot (just like host services do) and adjust to network changes dynamically.
I think you're right about the resolv.conf copy oneshot, but even if we fixed it we'd still have systems like mine that cant even download the container in the first place because it cant resolve the registry domains yet... I don't think putting systemd in every container for resolved is a sensible option. So fixing wicked or working around it are probably the two viable ways out of these ugly warts. -- Richard Brown Linux Distribution Engineer - Future Technology Team Phone +4991174053-361 SUSE Software Solutions Germany GmbH, Maxfeldstr. 5, D-90409 Nuernberg (HRB 36809, AG Nürnberg) Geschäftsführer: Felix Imendörffer -- To unsubscribe, e-mail: opensuse-kubic+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-kubic+owner@opensuse.org