traefik + whoami added

This commit is contained in:
2025-10-17 13:47:55 +02:00
parent 2f644afe60
commit 94bc5e1b0f
5 changed files with 99 additions and 0 deletions

15
whoami/compose.yaml Normal file
View File

@@ -0,0 +1,15 @@
services:
whoami:
# A container that exposes an API to show its IP address
image: containous/whoami
labels:
- traefik.enable=true
# Enable HTTPS
- traefik.http.routers.whoami.rule=Host(${TRAEFIK_HOST})
- traefik.http.routers.whoami.tls=true
- traefik.http.routers.whoami.tls.certresolver=letsencrypt
- traefik.http.routers.whoami.middlewares=secured@file # ip allowlist
# # Basic Auth - Users and Passwords must be added to volume/traefik/usersFile
# - traefik.http.routers.whoami.middlewares=basic-auth@file
# # Specify web port from container (if container is not listen on default port 80)
# - traefik.http.services.whoami.loadbalancer.server.port=8080