Support multi-port service routing for containers running on Marathon
This commit is contained in:
parent
0367034f93
commit
ec3e2c08b8
9 changed files with 498 additions and 134 deletions
13
docs/toml.md
13
docs/toml.md
|
@ -1027,6 +1027,7 @@ Labels can be used on containers to override default behaviour:
|
|||
- `traefik.docker.network`: Set the docker network to use for connections to this container. If a container is linked to several networks, be sure to set the proper network name (you can check with docker inspect <container_id>) otherwise it will randomly pick one (depending on how docker is returning them). For instance when deploying docker `stack` from compose files, the compose defined networks will be prefixed with the `stack` name.
|
||||
|
||||
If several ports need to be exposed from a container, the services labels can be used
|
||||
|
||||
- `traefik.<service-name>.port=443`: create a service binding with frontend/backend using this port. Overrides `traefik.port`.
|
||||
- `traefik.<service-name>.protocol=https`: assign `https` protocol. Overrides `traefik.protocol`.
|
||||
- `traefik.<service-name>.weight=10`: assign this service weight. Overrides `traefik.weight`.
|
||||
|
@ -1192,6 +1193,18 @@ Labels can be used on containers to override default behaviour:
|
|||
- `traefik.frontend.entryPoints=http,https`: assign this frontend to entry points `http` and `https`. Overrides `defaultEntryPoints`.
|
||||
- `traefik.frontend.auth.basic=test:$apr1$H6uskkkW$IgXLP6ewTrSuBkTrqE8wj/,test2:$apr1$d9hr9HBB$4HxwgUir3HP4EsggP/QNo0`: Sets basic authentication for that frontend with the usernames and passwords test:test and test2:test2, respectively
|
||||
|
||||
If several ports need to be exposed from a container, the services labels can be used
|
||||
|
||||
- `traefik.<service-name>.port=443`: create a service binding with frontend/backend using this port. Overrides `traefik.port`.
|
||||
- `traefik.<service-name>.portIndex=1`: create a service binding with frontend/backend using this port index. Overrides `traefik.portIndex`.
|
||||
- `traefik.<service-name>.protocol=https`: assign `https` protocol. Overrides `traefik.protocol`.
|
||||
- `traefik.<service-name>.weight=10`: assign this service weight. Overrides `traefik.weight`.
|
||||
- `traefik.<service-name>.frontend.backend=fooBackend`: assign this service frontend to `foobackend`. Default is to assign to the service backend.
|
||||
- `traefik.<service-name>.frontend.entryPoints=http`: assign this service entrypoints. Overrides `traefik.frontend.entrypoints`.
|
||||
- `traefik.<service-name>.frontend.auth.basic=test:$apr1$H6uskkkW$IgXLP6ewTrSuBkTrqE8wj/,test2:$apr1$d9hr9HBB$4HxwgUir3HP4EsggP/QNo0` Sets a Basic Auth for that frontend with the users test:test and test2:test2.
|
||||
- `traefik.<service-name>.frontend.passHostHeader=true`: Forward client `Host` header to the backend. Overrides `traefik.frontend.passHostHeader`.
|
||||
- `traefik.<service-name>.frontend.priority=10`: assign the service frontend priority. Overrides `traefik.frontend.priority`.
|
||||
- `traefik.<service-name>.frontend.rule=Path:/foo`: assign the service frontend rule. Overrides `traefik.frontend.rule`.
|
||||
|
||||
## Mesos generic backend
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue