This example shows a basic configuration of Traefik with a secure connection.
- A domain name, we assume for this example the domain
example.com
(access from internet and SSL certificate). - Cloudflare's account
- A working installation of
docker
anddocker-compose
- Port 80 and 443 are not used.
-
All the configurations are in the
docker-compose.yml
file. -
Copy from the root folder the
var.env
file and rename it in.env
. -
Change all the needed variables with the values of your case. The following list shows the needed for traefik and whoami test container:
DOMAIN #domain name
CLOUDFLARE_EMAIL #Cloudflare email account
CLOUDFLARE_API_KEY #Cloudflare API key
ACME_EMAIL #Reminder email for the generated certificate