Update alpine-install.func
This commit is contained in:
parent
db26e9805b
commit
c0c2f6544e
@ -98,8 +98,6 @@ msg_error() {
|
||||
setting_up_container() {
|
||||
msg_info "Setting up Container OS"
|
||||
|
||||
NS_VALUE=$(echo "$PCT_OPTIONS" | sed -n 's/.*-nameserver=\([^ ]*\).*/\1/p')
|
||||
|
||||
if [ "$UDHCPC_FIX" == "yes" ]; then
|
||||
CONFIG_FILE="/etc/udhcpc/udhcpc.conf"
|
||||
if grep -q '^#RESOLV_CONF=' "$CONFIG_FILE"; then
|
||||
@ -109,16 +107,6 @@ setting_up_container() {
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ "$NS_VALUE" != "" ] && [ "$NS_VALUE" != "Host" ]; then
|
||||
|
||||
CONFIG_FILE="/etc/udhcpc/udhcpc.conf"
|
||||
if grep -q '^#RESOLV_CONF=' "$CONFIG_FILE"; then
|
||||
sed -i 's/^#RESOLV_CONF=.*/RESOLV_CONF="no"/' "$CONFIG_FILE"
|
||||
else
|
||||
echo 'RESOLV_CONF="no"' >>"$CONFIG_FILE"
|
||||
fi
|
||||
fi
|
||||
|
||||
while [ $i -gt 0 ]; do
|
||||
if [ "$(ip addr show | grep 'inet ' | grep -v '127.0.0.1' | awk '{print $2}' | cut -d'/' -f1)" != "" ]; then
|
||||
break
|
||||
|
Loading…
x
Reference in New Issue
Block a user