Skip to content

Create a Sample App with Traefik

Bekker Stacks edited this page Sep 4, 2019 · 2 revisions

HTTP Endpoint:

To create a application for Traefik in HTTP Frontends:

$ docker stack deploy -c samples/docker-compose.sample-http-app.yml apps
Creating service apps_whoami

Application should be exposed on whoami.${DOMAIN}

$ curl http://whoami.${DOMAIN}
Hostname: ea75b484dbaf

HTTPS Endpoint:

If Traefik was setup with HTTPS, for SSL Termination on Traefik for the sample application:

$ docker stack deploy -c samples/docker-compose.sample-https-app.yml apps
Creating service apps_whoami

Application should be exposed on whoami.${DOMAIN}

$ curl http://whoami.${DOMAIN}
Hostname: ga39f420dgzo