dynamicdns: Fix writing configuration for no NAT

- When writing the configuration file for no NAT case, append then last
  part of the file instead of overwriting.

- Also 'echo' statements are missing leading to attempt to execute the
  config options instead of writing them to a file.
This commit is contained in:
Sunil Mohan Adapa 2016-02-01 11:00:46 +05:30
parent aa5efd4984
commit ea1e9b6e2a
No known key found for this signature in database
GPG Key ID: 36C361440C9BC971

View File

@ -167,11 +167,11 @@ doWriteCFG()
echo "NAT no" >> ${HELPERCFG} echo "NAT no" >> ${HELPERCFG}
# if this file is added ez-ipupdate will take ip form this interface # if this file is added ez-ipupdate will take ip form this interface
{ {
"interface=${default_interface}" echo "interface=${default_interface}"
# if this line is added to config file, ez-ipupdate will be launched on startup via init.d # if this line is added to config file, ez-ipupdate will be launched on startup via init.d
"daemon" echo "daemon"
"execute=${0} success" echo "execute=${0} success"
} > ${out_file} } >> ${out_file}
fi fi
fi fi
} }