LogoLogo
HomeDiscordYouTubeDisclaimer
  • Traefik v2.6+
    • Unraid
      • Config Files Explained
        • traefik.yml Example
        • fileConfig.yml Example
      • Proxying Your First App
        • Proxying an App with Multiple Exposed Ports
        • Proxying an App with a HTTPS WebUI
        • Choosing Your App Subdomain Manually
        • Enabling Authelia Server Authentication
        • Enabling Organizr server authentication
    • Docker Compose
      • Config Files Explained
        • traefik.yml Example
        • fileConfig.yml Example
      • Proxying Your First App
        • Proxying an App with Multiple Exposed Ports
        • Proxying an App with a HTTPS WebUI
        • Choosing Your App Subdomain Manually
        • Enabling Authelia Server Authentication
    • [BETA] Traefik Tunnel
  • 🎯DO I NEED AN UPDATE?
    • Update Me!
  • ❗DISCLAIMER
    • Read Our Disclaimer
Powered by GitBook
On this page

Was this helpful?

Export as PDF
  1. Traefik v2.6+
  2. Docker Compose
  3. Proxying Your First App

Proxying an App with a HTTPS WebUI

By default, Traefik connects to the application's backend via HTTP. If the application exposes it's WebUI via HTTPS, then we will need to tell Traefik to use this protocol.

If you are using docker-compose then you simply need to add a single line to the compose files under labels:

    labels:
      traefik.http.services.app.loadbalancer.server.scheme: https

WARNING

You must replace app with the name of your application that this label is being added to otherwise Traefik will see duplicates.

To show you a full example, we will add the label to an existing docker-compose.yml file for Adminer.

docker-compose.yml
version: '3'

services:
  adminer:
    container_name: adminer
    image: adminer
    networks:
      - proxy
    labels:
      traefik.enable: true
      traefik.http.routers.adminer.entryPoints: https
      traefik.http.services.adminer.loadbalancer.server.scheme: https
    restart: unless-stopped

networks:
  proxy:
    driver: bridge
    external: true

Now while in the same directory as the docker-compose.yml file, run the command docker-compose up -d and it should recreate the container for you with the latest labels. Now when you deploy your application, you will be able to visit it by going to your domain with the app name as the subdomain (APP-NAME.DOMAIN.COM).

PLEASE NOTE

You can add multiple of these labels at once before finally deploying your application.

Conclusion

Traefik will now use the HTTPS protocol specified to forward all traffic on to the app correctly.

PreviousProxying an App with Multiple Exposed PortsNextChoosing Your App Subdomain Manually

Last updated 3 years ago

Was this helpful?

In some cases, you may find that after changing the scheme to HTTPS, you will have to also specify the application's HTTPS port manually. You can do this by following the short guide on "".

Proxying an App with Multiple Exposed Ports