Skip to content
Open
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
10 changes: 5 additions & 5 deletions data/Dockerfiles/acme/acme.sh
Original file line number Diff line number Diff line change
Expand Up @@ -167,10 +167,10 @@ while true; do
DOVECOT_CERT_SERIAL_NEW="$(echo | openssl s_client -connect dovecot:143 -starttls imap 2>/dev/null | openssl x509 -inform pem -noout -serial | cut -d "=" -f 2)"
# Re-using previous acme-mailcow account and domain keys
if [[ ! -f ${ACME_BASE}/acme/key.pem ]]; then
log_f "Generating missing domain private rsa key..."
openssl genrsa 4096 > ${ACME_BASE}/acme/key.pem
log_f "Generating missing domain private key (ECDSA P-256)..."
openssl genpkey -algorithm EC -pkeyopt ec_paramgen_curve:P-256 > ${ACME_BASE}/acme/key.pem
else
log_f "Using existing domain rsa key ${ACME_BASE}/acme/key.pem"
log_f "Using existing domain key ${ACME_BASE}/acme/key.pem"
fi
if [[ ! -f ${ACME_BASE}/acme/account.pem ]]; then
log_f "Generating missing Lets Encrypt account key..."
Expand Down Expand Up @@ -352,7 +352,7 @@ while true; do
VALIDATED_CERTIFICATES+=("${CERT_NAME}")

# obtain server certificate if required
DOMAINS=${SERVER_SAN_VALIDATED[@]} /srv/obtain-certificate.sh rsa
DOMAINS=${SERVER_SAN_VALIDATED[@]} /srv/obtain-certificate.sh ecdsa
RETURN="$?"
if [[ "$RETURN" == "0" ]]; then # 0 = cert created successfully
CERT_AMOUNT_CHANGED=1
Expand Down Expand Up @@ -394,7 +394,7 @@ while true; do
CERT_NAME=${VALIDATED_DOMAINS_SORTED[0]}
VALIDATED_CERTIFICATES+=("${CERT_NAME}")
# obtain certificate if required
DOMAINS=${VALIDATED_DOMAINS_SORTED[@]} /srv/obtain-certificate.sh rsa
DOMAINS=${VALIDATED_DOMAINS_SORTED[@]} /srv/obtain-certificate.sh ecdsa
RETURN="$?"
if [[ "$RETURN" == "0" ]]; then # 0 = cert created successfully
CERT_AMOUNT_CHANGED=1
Expand Down
3 changes: 1 addition & 2 deletions data/Dockerfiles/acme/obtain-certificate-dns.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@ fi

TYPE=${1}
PREFIX=""
# only support rsa certificates for now
if [[ "${TYPE}" != "rsa" ]]; then
if [[ "${TYPE}" != "rsa" && "${TYPE}" != "ecdsa" ]]; then
log_f "Unknown certificate type '${TYPE}' requested"
exit 5
fi
Expand Down
3 changes: 1 addition & 2 deletions data/Dockerfiles/acme/obtain-certificate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@ ACME_BASE=/var/lib/acme

TYPE=${1}
PREFIX=""
# only support rsa certificates for now
if [[ "${TYPE}" != "rsa" ]]; then
if [[ "${TYPE}" != "rsa" && "${TYPE}" != "ecdsa" ]]; then
log_f "Unknown certificate type '${TYPE}' requested"
exit 5
fi
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -465,7 +465,7 @@ services:
condition: service_started
unbound-mailcow:
condition: service_healthy
image: ghcr.io/mailcow/acme:1.97
image: ghcr.io/mailcow/acme:2.00
dns:
- ${IPV4_NETWORK:-172.22.1}.254
environment:
Expand Down