Tidying
This commit is contained in:
parent
9d7e1c5263
commit
32403cbd1c
|
@ -230,8 +230,7 @@ function add_ddns_domain {
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ! grep -q "$CURRENT_DDNS_DOMAIN" "${INADYN_CONFIG_FILE}"; then
|
if ! grep -q "$CURRENT_DDNS_DOMAIN" "${INADYN_CONFIG_FILE}"; then
|
||||||
DDNS_HOSTNAMES=$(grep 'hostname ' "${INADYN_CONFIG_FILE}"| awk -F '{' '{print $2}' | sed 's| }||g')
|
sed -i "s|hostname .*|hostname = $DEFAULT_DOMAIN_NAME"
|
||||||
sed -i "s|hostname .*|hostname = {${DDNS_HOSTNAMES}, ${CURRENT_DDNS_DOMAIN} }|g" "${INADYN_CONFIG_FILE}"
|
|
||||||
fi
|
fi
|
||||||
chmod 600 "${INADYN_CONFIG_FILE}"
|
chmod 600 "${INADYN_CONFIG_FILE}"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue