Skip to content

using multiple apps #1

Description

@phmalek

When I use the docker-compose.yml file for the case where I have 2 apps, namely app1 and app2, strangely, it only opens app1. (I have addedd "url_base_pathname=/appx/" for both app1 and app2 and I have exposed them to 8050 and 8000 respectiveley). Could you share a docker-compose file functional for this case?

Here is my docker-compose.yml

`
version: "3.3"

services:
proxy:
image: traefik:v2.3
command:
--api=true
--api.insecure=true
--api.dashboard=true
--entryPoints.web.address=:80
--providers.docker
--providers.docker.watch=true
--providers.docker.swarmMode=true
--log.level=DEBUG
--ping.entrypoint=web
--passHostHeaders=false
ports:
- 1080:80
- 8080:8080
networks:
- dash-net
# depends_on:
# - dash
volumes:
- /var/run/docker.sock:/var/run/docker.sock
deploy:
replicas: 1
restart_policy:
condition: any
labels:
- traefik.enable=false
placement:
constraints:
- node.role == manager

dash:
image: app1
# build: .
networks:
- dash-net
deploy:
replicas: 1
restart_policy:
condition: any
labels:
- traefik.enable=true
- traefik.docker.network=dash-net
- traefik.http.routers.dash.rule=Host(localhost)
- traefik.http.services.dash.loadbalancer.server.port=8050

dash2:
image: app2
# build: .
networks:
- dash-net
deploy:
replicas: 1
restart_policy:
condition: any
labels:
- traefik.enable=true
- traefik.docker.network=dash-net
- traefik.http.routers.dash2.rule=Host(localhost)
- traefik.http.services.dash2.loadbalancer.server.port=8000

networks:
dash-net:
external: true
`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions