From 96f1d9f380159edacf3f4f229ead1d97a97084a9 Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Sat, 4 May 2024 12:14:30 +0200 Subject: [PATCH] mv/dns --- cd.sh | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/cd.sh b/cd.sh index 5c6f0a2..ee895e4 100644 --- a/cd.sh +++ b/cd.sh @@ -16,10 +16,10 @@ rwx \ cd_main () { cd_list_working_directory cd_set_environment_variables - cd_set_dns_resolving cd_set_packages_repositories cd_set_packages_configuration cd_set_https_verification_off + cd_set_dns_resolving cd_update_packages_catalog cd_install_packages_tools cd_install_ca_certificates @@ -164,19 +164,6 @@ Dir::Etc::SourceParts \"\"; cd_echo "CD_PROJECTS_URL" "CD_PROJECT_URL" } -cd_set_dns_resolving () { -local server -local servers -local text="" - cd_step "Set DNS resolving" - [ "${CD_DNS}" ] && servers="${CD_DNS}" || servers="${CD_DEFAULT_DNS}" - for server in ${servers} ; do - text="${text}nameserver ${server} -" - done - cd_write "${CD_DNS_FILE}" "${text}" -} - cd_set_packages_repositories () { local expression local file @@ -217,6 +204,19 @@ cd_set_https_verification_off () { fi } +cd_set_dns_resolving () { +local server +local servers +local text="" + cd_step "Set DNS resolving" + [ "${CD_DNS}" ] && servers="${CD_DNS}" || servers="${CD_DEFAULT_DNS}" + for server in ${servers} ; do + text="${text}nameserver ${server} +" + done + cd_write "${CD_DNS_FILE}" "${text}" +} + cd_update_packages_catalog () { cd_step "Update packages catalog" ${CD_CMD_UPDATE} || exit