disable systemd-resolved for server

This commit is contained in:
pvincent
2024-03-02 16:54:12 +04:00
parent cda020f4e0
commit abf8cac050
2 changed files with 10 additions and 2 deletions
+2 -2
View File
@@ -372,8 +372,8 @@ function check_resolv_conf() {
bridge_gw=$(lxc network get lxdbr0 ipv4.address | cut -d'/' -f1)
PREFIX="resolver:check" echo "container bridge is <$bridge_gw>"
resolver=$(grep nameserver /etc/resolv.conf | tail -n1 | cut -d ' ' -f2)
PREFIX="resolver:check" echo "container resolver is <$resolver>"
resolver=$(grep nameserver /etc/resolv.conf | head -n1 | cut -d ' ' -f2)
PREFIX="resolver:check" echo "first resolver is <$resolver>"
[[ "$bridge_gw" != "$resolver" ]] && return 21
return 0