[letsencrypt] Rename script for updating certificates

This patch renames the update-haproxy-cert script to
update-loadbalancer-cert to make the name more generic.
The change is necessary because support for ProxySQL
will be introduced in the next patch, requiring a name
that reflects broader applicability.

To keep the diff in the following patch clean and easier
to review, this patch focuses exclusively on the rename.

Change-Id: I15f9b5cf3976f4298cdc7da4530f2d7d09614e88
This commit is contained in:
Michal Arbet
2024-12-03 09:37:29 +01:00
parent b1be326178
commit 36ef420f82
3 changed files with 3 additions and 3 deletions

View File

@@ -34,7 +34,7 @@ COPY extend_start.sh /usr/local/bin/kolla_extend_start
RUN chmod 644 /usr/local/bin/kolla_extend_start \
&& sed -ri 's/session(\s+)required(\s+)pam_loginuid.so/session\1optional\2pam_loginuid.so/' /etc/pam.d/sshd
COPY update-haproxy-cert.sh /usr/bin/update-haproxy-cert
COPY update-loadbalancer-cert.sh /usr/bin/update-loadbalancer-cert
{{ macros.kolla_patch_sources() }}

View File

@@ -81,12 +81,12 @@ if [ "${INTERNAL_SET}" = "true" ] || [ "${EXTERNAL_SET}" = "true" ]; then
internal_cert_path=$(find /etc/letsencrypt/lego/internal/ -name '*.pem')
sed -i '/^$/d' ${internal_cert_path}
rsync -av -e "ssh -p ${port} -o StrictHostKeyChecking=no -o IdentityFile=/var/lib/letsencrypt/.ssh/id_rsa" ${internal_cert_path} haproxy@${server}:/var/lib/haproxy/haproxy-internal.pem --delete >/dev/null 2>&1
ssh -p ${port} -i /var/lib/letsencrypt/.ssh/id_rsa -o StrictHostKeyChecking=no haproxy@${server} "/usr/bin/update-haproxy-cert --internal"
ssh -p ${port} -i /var/lib/letsencrypt/.ssh/id_rsa -o StrictHostKeyChecking=no haproxy@${server} "/usr/bin/update-loadbalancer-cert --internal"
else
external_cert_path=$(find /etc/letsencrypt/lego/external/ -name '*.pem')
sed -i '/^$/d' ${external_cert_path}
rsync -av -e "ssh -p ${port} -o StrictHostKeyChecking=no -o IdentityFile=/var/lib/letsencrypt/.ssh/id_rsa" ${external_cert_path} haproxy@${server}:/var/lib/haproxy/haproxy.pem --delete >/dev/null 2>&1
ssh -p ${port} -i /var/lib/letsencrypt/.ssh/id_rsa -o StrictHostKeyChecking=no haproxy@${server} "/usr/bin/update-haproxy-cert --external"
ssh -p ${port} -i /var/lib/letsencrypt/.ssh/id_rsa -o StrictHostKeyChecking=no haproxy@${server} "/usr/bin/update-loadbalancer-cert --external"
fi
done