From d98c9cda2362e9167f83c55df93a71e2ed0d41b4 Mon Sep 17 00:00:00 2001 From: Kevin Veen-Birkenbach Date: Thu, 23 Jan 2025 01:39:59 +0100 Subject: [PATCH] Solved mailu bug --- .../files/nginx-docker-cert-deploy.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/roles/nginx-docker-cert-deploy/files/nginx-docker-cert-deploy.sh b/roles/nginx-docker-cert-deploy/files/nginx-docker-cert-deploy.sh index beab068d..9334ac85 100644 --- a/roles/nginx-docker-cert-deploy/files/nginx-docker-cert-deploy.sh +++ b/roles/nginx-docker-cert-deploy/files/nginx-docker-cert-deploy.sh @@ -12,6 +12,12 @@ docker_compose_instance_directory="$2" # Copy certificates cp -RvL "/etc/letsencrypt/live/$domain/"* "$docker_compose_instance_directory/certs" || exit 1 + +# This code is optimized for mailu +cp -v "/etc/letsencrypt/live/$domain/privkey.pem" "$docker_compose_instance_directory/certs/key.pem" || exit 1 +cp -v "/etc/letsencrypt/live/$domain/fullchain.pem" "$docker_compose_instance_directory/certs/cert.pem" || exit 1 + +# Set correct reading rights chmod a+r -v "$docker_compose_instance_directory/certs/"* # Flag to track if any Nginx reload was successful