Reverse Proxy
Why Use a Reverse Proxy?
A reverse proxy is a server that sits between your client devices and your backend servers. It helps manage and distribute incoming traffic, providing benefits like improved security, load balancing, and easier management of multiple services. Setting up a reverse proxy can make accessing your Plex server and other services more seamless and secure. Using a reverse proxy, you can map different services to subdomains of your main domain. For example:
Vaultwarden service available at http://yourserverip:11001 can be turned into https://vaultwarden.yourdomain.fr
Choosing a reverse proxy server
You could use Nginx or Apache but Traefik is awesome and is by far the best imo, here are a few advantages of Traefik:
Automatically discovers the right configuration for your services.
Built-in Let's Encrypt Integration (HTTPS) (Automatically handles SSL certificate generation and renewal with Let's Encrypt.)
Natively compliant with every major cluster technology, such as Kubernetes, Docker Swarm, AWS, and the list goes on
Ease of use
Built-in Middlewares such as authentication, rate limiting, IP whitelisting...
Configure Traefik
I recommend you also take a look at this guide.
first of all create config folder that will store SSL certificates and more:
Setup Cloudflare DNS records + SSL Mode to FULL (not strict)
If you plan to use http basic auth middleware for one of your services (only use over https) (for example to protect a service that would otherwise be freely accessible by anyone), you can generate your USERNAME + PASS with this command:
Example of traefik config in docker-compose.yml:
Last updated