From a4d644228ff60ec2ac8775b64dcaea4608ce6063 Mon Sep 17 00:00:00 2001 From: Daniel Golle Date: Mon, 13 Apr 2020 02:03:53 +0100 Subject: [PATCH] jail: replace /etc/resolv.conf with symlink in extroot+overlay Signed-off-by: Daniel Golle --- jail/jail.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/jail/jail.c b/jail/jail.c index 052a78e..87b671b 100644 --- a/jail/jail.c +++ b/jail/jail.c @@ -254,6 +254,8 @@ static int build_jail_fs(void) snprintf(jailetc, PATH_MAX, "%s/etc", jail_root); mkdir_p(jailetc, 0755); snprintf(jaillink, PATH_MAX, "%s/etc/resolv.conf", jail_root); + if (overlaydir) + unlink(jaillink); symlink("../tmp/resolv.conf.d/resolv.conf.auto", jaillink); } -- 2.25.1