diff --git a/tools/build_lxc.sh b/tools/build_lxc.sh index 0f1737806c..580581b83a 100755 --- a/tools/build_lxc.sh +++ b/tools/build_lxc.sh @@ -32,7 +32,7 @@ CONTAINER_IP=${CONTAINER_IP:-192.168.1.50} CONTAINER_CIDR=${CONTAINER_CIDR:-$CONTAINER_IP/24} CONTAINER_NETMASK=${CONTAINER_NETMASK:-255.255.255.0} CONTAINER_GATEWAY=${CONTAINER_GATEWAY:-192.168.1.1} -NAMESERVER=${NAMESERVER:-$CONTAINER_GATEWAY} +NAMESERVER=${NAMESERVER:-`cat /etc/resolv.conf | grep nameserver | head -1 | cut -d " " -f2`} COPYENV=${COPYENV:-1} DEST=${DEST:-/opt/stack} WAIT_TILL_LAUNCH=${WAIT_TILL_LAUNCH:-1}