Skip to content

Commit

Permalink
properly catch certbot logs
Browse files Browse the repository at this point in the history
  • Loading branch information
ebarault committed Mar 6, 2019
1 parent 0a95d07 commit 6b1ac39
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions scripts/run_certbot.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,10 @@ logger_info() {
}

issueCertificate() {
certbot certonly --agree-tos --renew-by-default --non-interactive --max-log-backups 100 --email $EMAIL $CERTBOT_ARGS -d $1 &>/dev/null
return $?
certbot_response=`certbot certonly --agree-tos --renew-by-default --non-interactive --max-log-backups 100 --email $EMAIL $CERTBOT_ARGS -d $1 2>&1`
certbot_return_code=$?
logger_info "${certbot_response}"
return ${certbot_return_code}
}

copyCertificate() {
Expand Down Expand Up @@ -73,7 +75,7 @@ processCertificates() {
domains="${domains} -d ${altname}"
else
domains="${altname}"
fi
fi
fi
done

Expand Down

0 comments on commit 6b1ac39

Please sign in to comment.