1
0
mirror of https://github.com/Mailu/Mailu.git synced 2024-12-04 10:24:41 +02:00

Fix 3129, thanks to Games-Crack

This commit is contained in:
Florent Daigniere 2024-01-18 17:30:01 +01:00
parent 5fcbe7a2fe
commit bbfde0badc
2 changed files with 5 additions and 4 deletions

View File

@ -5,14 +5,14 @@ function dump() {
traefik-certs-dumper file --version ${TRAEFIK_VERSION:-v1} --crt-name "cert" --crt-ext ".pem" --key-name "key" --key-ext ".pem" --domain-subdir --dest /tmp/work --source /traefik/acme.json > /dev/null
if [[ -f /tmp/work/${DOMAIN}/cert.pem && -f /tmp/work/${DOMAIN}/key.pem && -f /output/cert.pem && -f /output/key.pem ]] && \
diff -q /tmp/work/${DOMAIN}/cert.pem /output/cert.pem >/dev/null && \
diff -q /tmp/work/${DOMAIN}/key.pem /output/key.pem >/dev/null ; \
if [[ -f "/tmp/work/${DOMAIN}/cert.pem" && -f "/tmp/work/${DOMAIN}/key.pem" && -f /output/cert.pem && -f /output/key.pem ]] && \
diff -q "/tmp/work/${DOMAIN}/cert.pem" /output/cert.pem >/dev/null && \
diff -q "/tmp/work/${DOMAIN}/key.pem" /output/key.pem >/dev/null ; \
then
echo "$(date) Certificate and key still up to date, doing nothing"
else
echo "$(date) Certificate or key differ, updating"
mv /tmp/work/${DOMAIN}/*.pem /output/
mv "/tmp/work/${DOMAIN}"/*.pem /output/
fi
}

View File

@ -0,0 +1 @@
Add required quotes to traefik-certdumper to ensure that shell characters are usable.