Docker-compose traefik PathPrefixStrip不能正常工作

我有个问题让我生气,请帮助我。

我想从一个免费的无ip子域访问我的所有应用程序,所以我认为traefik可以为我做这个,我想访问所有我的应用程序,如:

mysubdomain.no-ip.com/emby mysubdomain.no-ip.com/pydio mysubdomain.no-ip.com/adminer... 

这是我的docker组成:

 version: "2" services: db: image: linuxserver/mariadb restart: always environment: MYSQL_ROOT_PASSWORD: "test" labels: - "traefik.enable=false" volumes: - ./config/mariadb:/etc/mysql/ ports: - '3306:3306' adminer: image: adminer restart: always labels: - "traefik.enable=true" - "traefik.backend=adminer" - "traefik.frontend.rule=PathPrefixStrip:/dbadmin" - "traefik.backend.port=8080" volumes: - ./config/adminer:/config emby: image: emby/embyserver:latest restart: always labels: - "traefik.enable=true" - "traefik.backend=emby" - "traefik.frontend.rule=PathPrefixStrip:/media" - "traefik.backend.port=8096" volumes: - ./config/emby:/config cloud: image: linuxserver/pydio:latest restart: always environment: PGID: "1000" PUID: "1000" labels: - "traefik.enable=true" - "traefik.backend=cloud" - "traefik.frontend.rule=PathPrefixStrip:/cloud" - "traefik.backend.port=443" - "traefik.protocol=https" volumes: - ./config/cloud:/config - ./data/test:/data organizr: image: lsiocommunity/organizr restart: always environment: PGID: "1000" PUID: "1000" TZ: "Europe/Paris" labels: - "traefik.enable=true" - "traefik.backend=organizr" - "traefik.frontend.rule=PathPrefixStrip:/" - "traefik.backend.port=80" volumes: - ./config/organizr:/config - ./data/organizr:/data traefik: image: traefik:1.3.3 command: --web --docker --docker.domain=traefik --logLevel=DEBUG #-c /dev/null --web --docker --logLevel=INFO restart: always ports: - '80:80' - '443:443' - '8080:8080' labels: - "traefik.enable=false" volumes: - /var/run/docker.sock:/var/run/docker.sock - ./traefik.toml:/traefik.toml - ./config/traefik/data:/data - ./config/traefik/sslcerts:/ssl 

我的traefik.toml

 # defaultEntryPoints must be at the top because it should not be in any table below defaultEntryPoints = ["http", "https"] InsecureSkipVerify = true [web] # Port for the status page address = ":8080" # Entrypoints, http and https [entryPoints] # http should be redirected to https [entryPoints.http] address = ":80" [entryPoints.http.redirect] entryPoint = "https" # https is the default [entryPoints.https] address = ":443" [entryPoints.https.tls] [[entryPoints.https.tls.certificates]] CertFile = "/ssl/tls.crt" KeyFile = "/ssl/tls.key" [retry] # Enable ACME (Let's Encrypt): automatic SSL # [acme] # # caServer = "https://acme-staging.api.letsencrypt.org/directory" # email = "test@gmail.com" # storage = "acme.json" # or "traefik/acme/account" if using KV store # entryPoint = "https" # onDemand = false # OnHostRule = true [docker] endpoint = "unix:///var/run/docker.sock" domain = "localhost" watch = true exposedbydefault = false 

所以我只有一个应用程序,像一个魅力工作:呃。

adminer semms正常工作,加载css和其他资产,但是当我提交表单时,它发送给我本地主机/服务器=数据库和用户名=testing它应该送我到本地/ dbadmin /服务器=数据库和用户名=testing

当我访问本地主机/云/它加载我一个空白页面,如果我打开Chrome的控制台:

 pydio.material.min.css Failed to load resource: the server responded with a status of 404 () pydio.boot.min.js Failed to load resource: the server responded with a status of 404 () cloud:18 Uncaught ReferenceError: PydioBootstrap is not defined at cloud:18 pydio.material.min.css Failed to load resource: the server responded with a status of 404 () 

事实上,它尝试从本地主机/插件,而不是从本地/云/插件加载插件…我看到很多与此有关的github问题,但似乎在1.3.3版本中纠正,我尝试1.3.3 ,最新…

做pydio和adminer需要支持反向代理吗?

对不起,我的英语不好。

在traefik中,PathPrefixStrip和入口点中的redirect目前不能一起工作 。 所以如果你的请求转到http而不是https,你会得到一个错误。

在我自己的演示中 ,我只是在端口80上设置nginx来发送redirect作为一个短期的解决方法,直到上述问题得到解决。