Hello, I have two service API and DBManager, I've added
API service
api_1
"labels": [
"traefik.enable=true",
"traefik.http.routers.api.rule=Host(`app.localhost`) && PathPrefix(`/api`)",
"traefik.http.routers.api.entrypoints=web-secure",
"traefik.http.routers.api.tls=true",
"traefik.http.services.api.loadbalancer.server.port=5002"
],
"networks": [
"network"
],
"ports": [
"5002:5002"
],
This is my DB
DBManager service
dbmanager_1
"labels": [
"traefik.enable=true",
"traefik.http.routers.dbmanager.rule=Host(`app.localhost`) && PathPrefix(`/dbmanager/`)",
"traefik.http.routers.dbmanager.entrypoints=web-secure",
"traefik.http.routers.dbmanager.tls=true",
"traefik.http.services.dbmanager.loadbalancer.server.port=5005"
],
"networks": [
"network"
],
"ports": [
"5005:5005"
],
My proxy container
"proxy": {
"command": [
"--api",
"--api.debug",
"--api.insecure=true",
"--log.level=DEBUG",
"--providers.docker=true",
"--providers.docker.exposedbydefault=false",
"--entrypoints.web-insecure.address=:80",
"--entrypoints.web-secure.address=:443",
"--entrypoints.web-secure.forwardedheaders.insecure"
],
"image": "traefik:v2.9.8",
"networks": ["network"],
"ports": [
"80:80",
"443:443",
"8080:8080"
],
Issue is, accessing app.localhost/api works locally, so does app.localhost/dbmanager but communication between these 2 when using the traefik host (app.localhost) does not work. It gives me error 500