From: Lukas Schauer Date: Fri, 8 Jan 2016 19:33:59 +0000 (+0100) Subject: do not change exit code of loop in command_sign_domains X-Git-Tag: v0.1.0~72 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a7934fe72d066746a830475b757a18fac569d837;p=thirdparty%2Fdehydrated.git do not change exit code of loop in command_sign_domains --- diff --git a/letsencrypt.sh b/letsencrypt.sh index 07d8b1d..43ef21e 100755 --- a/letsencrypt.sh +++ b/letsencrypt.sh @@ -358,7 +358,7 @@ command_sign_domains() { fi # Generate certificates for all domains found in domains.txt. Check if existing certificate are about to expire - <"${DOMAINS_TXT}" sed 's/^[[:space:]]*//g;s/[[:space:]]*$//g' | grep -vE '^(#|$)' | while read -r line; do + <"${DOMAINS_TXT}" sed 's/^[[:space:]]*//g;s/[[:space:]]*$//g' | (grep -vE '^(#|$)' || true) | while read -r line; do domain="$(printf '%s\n' "${line}" | cut -d' ' -f1)" morenames="$(printf '%s\n' "${line}" | cut -s -d' ' -f2-)" cert="${BASEDIR}/certs/${domain}/cert.pem" @@ -409,7 +409,7 @@ command_sign_domains() { # shellcheck disable=SC2086 sign_domain ${line} - done || true + done # remove temporary domains.txt file if used [[ -n "${PARAM_DOMAIN:-}" ]] && rm -f "${DOMAINS_TXT}"