You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/post/2023/10/12/configure-lets-encrypt-acme-with-ionos-api-for-synology-dsm/index.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,10 +9,10 @@ tags:
9
9
- Lets Encrypt
10
10
---
11
11
# Introduction
12
-
I've [just setup]({{< ref "/post/2023/10/12/configure-lets-encrypt-acme-with-ionos-api-in-openwrt" >}}) a Let's encrypt certificate for my OpenWRT router. I would like to do the same for my Synology NAS. However, this one is a bit more complex, since I'm running a lot of docker container on that machine and also use the reverse proxy feature. So I'll need a wildcard certificate. Unfortunately, DSM doesn't support Let's encrypt certificates using DNS validation, so I'll have to do things manually. Luckily [some people](https://www.christosgeo.com/2022/02/03/renew-lets-encrypt-certificates-on-synology-using-acme-sh/) already experimented with this problem and documented them.
12
+
I've (just setup]({{< ref "/post/2023/10/12/configure-lets-encrypt-acme-with-ionos-api-in-openwrt" >}}) a Let's encrypt certificate for my OpenWRT router. I would like to do the same for my Synology NAS. However, this one is a bit more complex, since I'm running a lot of docker container on that machine and also use the reverse proxy feature. So I'll need a wildcard certificate. Unfortunately, DSM doesn't support Let's encrypt certificates using DNS validation, so I'll have to do things manually. Luckily (some people](https://www.christosgeo.com/2022/02/03/renew-lets-encrypt-certificates-on-synology-using-acme-sh/) already experimented with this problem and documented them.
13
13
14
14
# Create Ionos API credentials
15
-
See [this documentation](https://developer.hosting.ionos.de/docs/getstarted#createKey) on how to create a new API key. I've created additonally a subdomain `local` which I'll be using for all my local network stuff. I assume you'll need to have the subdomain already configured in Ionos before you'll request any certificates for subdomains.
15
+
See (this documentation](https://developer.hosting.ionos.de/docs/getstarted#createKey) on how to create a new API key. I've created additonally a subdomain `local` which I'll be using for all my local network stuff. I assume you'll need to have the subdomain already configured in Ionos before you'll request any certificates for subdomains.
16
16
17
17
# Preparations
18
18
The suggestion is to run the ACME script inside a docker container. Additionally a separate DSM admin user should be used for managing the certificate renewal process. The user must be an admin, but can be denied access to all DSM Applications. You'll have to login once for this user, to complete the 2FA setup.
@@ -37,7 +37,7 @@ export SYNO_Create=1
37
37
Change the values to your needs. The `SYNO_Username` and password are of the account you've created earlier. The `IONOS_` parameters are from the API credential creation of Ionos.
38
38
39
39
## The Container
40
-
I'm using Portainer for most of my docker stuff. But since I'm following [these instructions](https://www.christosgeo.com/2022/02/03/renew-lets-encrypt-certificates-on-synology-using-acme-sh/) I'll be configuring this container via the DSM console.
40
+
I'm using Portainer for most of my docker stuff. But since I'm following (these instructions](https://www.christosgeo.com/2022/02/03/renew-lets-encrypt-certificates-on-synology-using-acme-sh/) I'll be configuring this container via the DSM console.
41
41
42
42
Enabe automatic restarts and give it a simple name like acme.
43
43
@@ -65,7 +65,7 @@ I had problems with my existing certs which weren't trusted by the docker contai
65
65
[Fri Oct 13 00:12:29 UTC 2023] Success
66
66
```
67
67
68
-
The list of certificates now show the uploaded certificate from lets encrypt, but its not in use anywhere inside the DSM. According to [this wiki](https://github.com/acmesh-official/acme.sh/wiki/deployhooks#20-deploy-the-certificate-to-synology-dsm), it must be assigned manually:
68
+
The list of certificates now show the uploaded certificate from lets encrypt, but its not in use anywhere inside the DSM. According to (this wiki](https://github.com/acmesh-official/acme.sh/wiki/deployhooks#20-deploy-the-certificate-to-synology-dsm), it must be assigned manually:
69
69
70
70
```
71
71
Afterwards, the certificate should show up inside Control Panel -> Security -> Certificates & can be assigned to specific services or set as the default certificate.
@@ -80,19 +80,19 @@ After some minor problems with the `synology_dsm` deploy hook, I've got it all r
80
80
I've just witnessed another expired certificate without my knowing. According to the acme container, it should be renewed only in a month, but is already expired for 2 days:
81
81
82
82
```bash
83
-
2024/04/11 00:49:03 stdout [Wed Apr 10 22:49:03 UTC 2024] Skip, Next renewal time is: [1;32m2024-05-11T22:49:51Z [0m
83
+
2024/04/11 00:49:03 stdoutWed Apr 10 22:49:03 UTC 2024 Skip, Next renewal time is: 2024-05-11T22:49:51Z
84
84
```
85
85
86
86
But according to the logs, acme already tried to renew a certificate in March 2024:
87
87
88
88
```bash
89
-
2024/03/13 23:49:51 stdout [Wed Mar 13 22:49:51 UTC 2024] [1;32mCert success. [0m
89
+
2024/03/13 23:49:51 stdoutWed Mar 13 22:49:51 UTC 2024 Cert success.
90
90
```
91
91
92
92
It failed to update the certificate in the DSM again:
93
93
94
94
```bash
95
-
2024/03/13 23:49:59 stdout [Wed Mar 13 22:49:59 UTC 2024] [1;31mUnable to authenticate to https://myds:5001 - check your username & password. [0m
95
+
2024/03/13 23:49:59 stdoutWed Mar 13 22:49:59 UTC 2024] Unable to authenticate to https://myds:5001 - check your username & password.
96
96
```
97
97
98
98
I've tried again to configure the deploy hook but I couldn't get past the authentication:
0 commit comments