Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Backports: Let's Encrypt fixes #296

Merged
merged 3 commits into from
Feb 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docker/haproxy/haproxy-ssh/update-haproxy-cert.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ function haproxy_transaction_start {
cert_input_sha1=$(openssl x509 -noout -fingerprint -sha1 -inform pem -in ${cert_input} | awk -F '=' '{print $2}' | sed -e 's/://g')
cert_dest_sha1=$(echo "show ssl cert *${cert_dest}" | socat unix-connect:/var/lib/kolla/haproxy/haproxy.sock - | awk -F 'SHA1 FingerPrint: ' '{print $2}' | sed '/^$/d')
if [ "${cert_input_sha1}" = "${cert_dest_sha1}" ]; then
log_info "[${cert_dest} - update] Transaction ${cert_input} -> ${cert_dest} successfull."
log_info "[${cert_dest} - update] Transaction ${cert_input} -> ${cert_dest} successful."
else
log_error "[${cert_dest} - update] Transaction ${cert_input} -> ${cert_dest} failed, SHA1 fingerprint of ${cert_input} is not the same as uploaded one."
exit 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ if [ "${INTERNAL_SET}" = "true" ] || [ "${EXTERNAL_SET}" = "true" ]; then
fi


if ip a | egrep -q "${LETSENCRYPT_VIP_ADDRESSES}"; then
if /usr/sbin/ip a | egrep -q "${LETSENCRYPT_VIP_ADDRESSES}"; then
log_info "[${FQDN} - cron] This Letsencrypt-lego host is active..."
if [ "${LETSENCRYPT_INTERNAL_FQDNS}" != "" ]; then
log_info "[${FQDN} - cron] Processing domains ${LETSENCRYPT_INTERNAL_FQDNS}"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,12 @@ if [ "${INTERNAL_SET}" = "true" ] || [ "${EXTERNAL_SET}" = "true" ]; then
server=$(echo $i | awk -F ':' '{print $1}')
port=$(echo $i | awk -F ':' '{print $2}')

if ! ip a | grep -q "${server}"; then
if ! /usr/sbin/ip a | grep -q "${server}"; then

log_info "[${FQDN} - hook] Rsync lego data /etc/letsencrypt/lego/ to server ${server} and port ${port}"
rsync -a -e "ssh -p ${port} -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o IdentityFile=/var/lib/letsencrypt/.ssh/id_rsa" /etc/letsencrypt/lego/ haproxy@${server}:/etc/letsencrypt/lego/ --delete >/dev/null 2>&1
if [ "$?" -eq 0 ]; then
log_info "[${FQDN} - hook] Rsync Successfull."
log_info "[${FQDN} - hook] Rsync Successful."
fi

else
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
fixes:
- |
Fixes the issue with command not found within letsencrypt-lego container.
`LP#2051111 <https://launchpad.net/bugs/2051111>`__
Loading