Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/docker/10.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Docker 在非HTTP端口上使用Traefik和TLS(acme插件)进行HTTP通信_Docker_Traefik - Fatal编程技术网

Docker 在非HTTP端口上使用Traefik和TLS(acme插件)进行HTTP通信

Docker 在非HTTP端口上使用Traefik和TLS(acme插件)进行HTTP通信,docker,traefik,Docker,Traefik,与问题“”不同,我在默认http端口上运行Traefik(>1.7) 我想为8448上的一个服务的HTTP流量配置一个附加入口点。因此,我已将此入口点添加到我的traefik.toml: defaultEntryPoints = ["http", "https"] logLevel = "DEBUG" [entryPoints] [entryPoints.http] address = ":80" [entryPoints.http.redirect] entryPoi

与问题“”不同,我在默认http端口上运行Traefik(
>1.7

我想为
8448
上的一个服务的HTTP流量配置一个附加入口点。因此,我已将此入口点添加到我的
traefik.toml

defaultEntryPoints = ["http", "https"]
logLevel = "DEBUG"

[entryPoints]
  [entryPoints.http]
  address = ":80"
    [entryPoints.http.redirect]
    entryPoint = "https"
  [entryPoints.https]
  address = ":443"
    [entryPoints.https.tls]
  [entryPoints.synapse]
  address = ":8448"
    [entryPoints.synapse.tls]

[api]

[acme]
email = "webmaster@example.com"
storage = "acme.json"
entryPoint = "https"
onHostRule = true
  [acme.httpChallenge]
  entryPoint = "http"

[docker]
endpoint = "unix:///var/run/docker.sock"
domain = "example.com"
watch = true
exposedByDefault = false
我的docker服务通过以下标签使用此端口:

labels:
  - traefik.enable=true
  - traefik.clients.frontend.rule=Host:matrix.example.com
  - traefik.clients.port=8008
  - traefik.clients.docker.network=proxy
  - traefik.federation.frontend.rule=Host:matrix.example.com
  - traefik.federation.port=8448
  - traefik.federation.docker.network=proxy
  - traefik.federation.frontend.entryPoints=synapse
不幸的是,Traefik根本不公开这个端口,即使我的docker容器这样做了。日志没有显示任何错误,但显示入口点是由Traefik设置的

有人知道我做错了什么吗


此设置按预期适用于其他入口点。

的端口443需要加密,这是一个“让我们加密”约束(或的端口80)


或者,您可以使用。

端口80和443。Traefik已经为
客户端
段获取了一个证书,该证书可以重新用于联合段。我如何配置以便Traefik使用现有证书?如果我配置DNS质询,它将按照问题帖子中所示的方式工作?我想你可以通过使用来实现你想要的。你能给我一个提示吗?你的确切意思是什么?