aboutsummaryrefslogtreecommitdiffstats
path: root/matrix-server/certbot/scripts/renew-certificates.sh
blob: e46d412d6f4372a517aeae1ac5c002c425081554 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/bash

# Certificates exist
if [ -d /etc/letsencrypt/live/davole.com ]; then
  # Check certificates and renew them
  certbot renew --http-01-port=380

  # Concatenate certificates
  . /etc/scripts/concatenate-certificates.sh

  # Update certificates in HAProxy
  . /etc/scripts/update-haproxy-certificates.sh

# Certificates don't exist
else
  #  Execute certificate creation script
  . /etc/scripts/create-certificates.sh
fi