diff options
author | Daniel Baumann <mail@daniel-baumann.ch> | 2016-06-01 13:56:36 +0000 |
---|---|---|
committer | Daniel Baumann <mail@daniel-baumann.ch> | 2016-06-01 13:56:36 +0000 |
commit | ac9d7da1d6f69a0a6fbb8e3729a24b9fa775f923 (patch) | |
tree | 38a95003274e9ae485abef49d36501d078fe0bf4 /share/scripts/debconf.d | |
parent | Adding upstream version 20160515. (diff) | |
download | open-infrastructure-compute-tools-ac9d7da1d6f69a0a6fbb8e3729a24b9fa775f923.tar.xz open-infrastructure-compute-tools-ac9d7da1d6f69a0a6fbb8e3729a24b9fa775f923.zip |
Adding upstream version 20160601.upstream/20160601
Signed-off-by: Daniel Baumann <mail@daniel-baumann.ch>
Diffstat (limited to 'share/scripts/debconf.d')
-rwxr-xr-x | share/scripts/debconf.d/0001-preseed-file | 4 | ||||
-rwxr-xr-x | share/scripts/debconf.d/0003-debconf | 20 |
2 files changed, 22 insertions, 2 deletions
diff --git a/share/scripts/debconf.d/0001-preseed-file b/share/scripts/debconf.d/0001-preseed-file index 82d2049..03976d2 100755 --- a/share/scripts/debconf.d/0001-preseed-file +++ b/share/scripts/debconf.d/0001-preseed-file @@ -30,12 +30,12 @@ then # user specified one or more preseed files through commandline option db_set cnt-debconf/preseed-file "${PRESEED_FILE}" db_fset cnt-debconf/preseed-file seen true -elif ls "${CONFIG}"/* > /dev/null 2>&1 +elif ls "${CONFIG}"/*.cfg > /dev/null 2>&1 then # user has not specified preseed files through commandline option, # showing debconf selection dialog for global preseed file. - FILES="$(cd ${CONFIG} && find * -not -type d -and -not -name '*.cfg' -and -not -name '*.in' -and -not -name '*.sh')" + FILES="$(cd ${CONFIG} && find . -type f -name '*.cfg' -printf '%P\n' | sort)" PRESEED_FILES="$(for FILE in ${FILES}; do echo -n "${FILE}, "; done | sed -e 's|, $||')" if [ -n "${PRESEED_FILES}" ] diff --git a/share/scripts/debconf.d/0003-debconf b/share/scripts/debconf.d/0003-debconf index df14ef0..baf6879 100755 --- a/share/scripts/debconf.d/0003-debconf +++ b/share/scripts/debconf.d/0003-debconf @@ -1041,6 +1041,26 @@ Internal_options () fi echo "HOST_COMMAND=\"${HOST_COMMAND}\"" >> "${DEBCONF_TMPDIR}/debconf.default" + + if db_get cnt-debconf/auto + then + CNT_AUTO="${RET:-FQDN}" # string (w/o empty) + + case "${CNT_AUTO}" in + FQDN) + CNT_AUTO="$(hostname -f)" + ;; + esac + fi + + echo "CNT_AUTO=\"${CNT_AUTO}\"" >> "${DEBCONF_TMPDIR}/debconf.default" + + if db_get cnt-debconf/bind + then + BIND="${RET}" # string (w/ empty) + fi + + echo "BIND=\"${BIND}\"" >> "${DEBCONF_TMPDIR}/debconf.default" } Distribution |