Synology Nas Reverse Proxy
How to Install Plausible on Your Synology NAS and Synology: How to Add Wildcard Certificate are great guides to setting up a Plausible Docker image on your NAS and exposing it to the internet, but they are long. This blog post is a generic and condensed guide to follow in order to reverse proxy a Docker image running on your NAS and exposing it to the internet. To follow this guide, you will need to own a domain name.
Create a Dynamic DNS Entry
- In your NAS “Control Panel”, click “External Access” from the sidebar
- Click the “DDNS” tab
- Click “Add” button
- Add hostname
- In the “External Address” dropdowns, click “Auto”
Expose Your NAS via Dynamic DNS
- In your NAS “Control Panel”, click “Security” from the sidebar
- Click the “Certificate” tab
- Select the “Add a new certificate” radio selector
- Select the “Get a certificate from Let’s Encrypt” radio selector
- In the “Domain name” text field input: “<your-domain>.synology.me”
- In the “Subject Alternative Name” text field input: “*.<your-domain>.synology.me”
- this last step is important in order to have wild card routes
Reverse Proxy a Docker Image
- In your NAS “Control Panel”, click “Login Portal” from the sidebar
- Click “Advanced” tab
- Click “Reverse Proxy” button
- Click “Create” button
- note, the Destination port needs to match the port defined in the Docker Compose yml
The best part of this is Synology will auto-renew your CA certifications via Let’s Encrypt.