【问题标题】:Traefik TLS handshake error from xx.xxx.xx.xxx:40748: EOF from Jira Webhook来自 xx.xxx.xx.xxx:40748 的 Traefik TLS 握手错误:来自 Jira Webhook 的 EOF
【发布时间】:2021-10-04 08:34:54
【问题描述】:

我将 traefik 与 jenkins docker 映像一起使用,并在那里安装了 jira 触发器插件。我还在 Jira 上创建了一个 webhook,但它不运行 jenkins 作业。我得到的唯一日志是:

traefik | time="2021-10-01T13:46:20Z" level=debug msg="Serving default certificate for request: \"\""
traefik | time="2021-10-01T13:46:20Z" level=debug msg="http: TLS handshake error from xx.xxx.xx.xxx:40748: EOF"

我会补充一点,这些日志仅在执行 webbhok 中定义的操作后才会出现。之前,jenkins 是独立的,我对这个插件没有任何问题。

我的配置:

docker-compose.yml

version: "3.8"
    services:
      traefik:
        image: "traefik:v2.0"
        container_name: traefik
        command:
          - --log.level=DEBUG
          - --entrypoints.web.address=:80
          - --entrypoints.web-secure.address=:443
          - --api.dashboard=true
          - --providers.docker=true
          - --providers.file.directory=/configuration/
          - --providers.file.watch=true
        ports:
          - "80:80"
          - "443:443"
        volumes:
          - /var/run/docker.sock:/var/run/docker.sock:ro
          - ./traefik/configuration/:/configuration/
          - ./traefik/certs/:/certs/
    
        jenkins:
          image: jenkins/jenkins:jdk11
          restart: always
          container_name: jenkins
          volumes:
              - /var/jenkins_home
          environment:
            - JENKINS_OPTS="--prefix=/jenkins"
          labels:
            - traefik.http.routers.jenkins-http.entrypoints=web
            - traefik.http.routers.jenkins-http.rule=Host(`<my_doamin>`) && PathPrefix(`/jenkins`)
            - traefik.http.routers.jenkins-http.middlewares=jenkins-https
            - traefik.http.middlewares.jenkins-https.redirectscheme.scheme=https
            - traefik.http.routers.jenkins.entrypoints=web-secure
            - traefik.http.routers.jenkins.rule=Host(`<my_doamin>`) && PathPrefix(`/jenkins`)
            - traefik.http.routers.jenkins.tls=true

配置/证书.toml

[[tls.certificates]]
   certFile = "/certs/cert.cert"
   keyFile = "/certs/key.key"

[tls.stores]
  [tls.stores.default]
    [tls.stores.default.defaultCertificate]
      certFile = "/certs/cert.cert"
      keyFile  = "/certs/key.key"

Jira webhook 网址:https:///jenkins/jira-trigger-webhook-receiver/

如何解决 TLS 握手错误?

【问题讨论】:

    标签: jenkins traefik jenkins-jira-trigger


    【解决方案1】:

    我找到了解决方案,只需将域证书替换为已加入的证书即可。

    cat <my_domain>.crt DigiCertCA.crt TrustedRoot.crt > joined_certificate.crt
    

    【讨论】:

    • 您的答案可以通过额外的支持信息得到改进。请edit 添加更多详细信息,例如引用或文档,以便其他人可以确认您的答案是正确的。你可以找到更多关于如何写好答案的信息in the help center
    猜你喜欢
    • 2020-01-07
    • 2020-09-20
    • 1970-01-01
    • 1970-01-01
    • 2020-11-22
    • 1970-01-01
    • 2021-06-20
    • 2021-05-20
    • 2020-10-11
    相关资源
    最近更新 更多