Giter Site home page Giter Site logo

Comments (4)

my-dlq avatar my-dlq commented on July 20, 2024

返回http状态码403,而不是404,说明流量已经流入服务器,没有通过验证。具体问题,可以猜一下:

1.检查证书是否有误。
2.本人使用的ingress的部署文件deployment资源中指定端口为hostport模式,即使用物理机的端口。检查traefik容器所运行的服务器端口是否能正常访问。
3.试试代理别的服务,如nginx服务,配置一个traefik https路由规则进行代理,进行尝试。
4.可以降低traefik配置文件中的日志级别,访问出错后观察容器日志,查看有无相关错误信息。

大晚上睡觉前暂时只能想这么多,实在不行可以将配置发我邮箱 [email protected] 给看下。

from blog-example.

quanzaiyu avatar quanzaiyu commented on July 20, 2024

我是用的是Docker Desktop中继承的Kubernetes,没使用虚拟机。

image

尝试代理其他服务也是一样的,比如Nginx:

apiVersion: traefik.containo.us/v1alpha1
kind: IngressRoute
metadata:
  name: nginx-route
  namespace: nginx
spec:
  entryPoints:
    - web
  routes:
    - match: Host(`nginx.test.com`)
      kind: Rule
      services:
        - name: nginx
          port: 80

---

apiVersion: traefik.containo.us/v1alpha1
kind: IngressRoute
metadata:
  name: nginx-route
  namespace: nginx
spec:
  entryPoints:
    - websecure
  tls:
    secretName: nginx-test-tls
    hosts:
      - nginx.test.com
  routes:
    - match: Host(`nginx.test.com`)
      kind: Rule
      services:
        - name: nginx
          port: 80

结果如下:
HTTP:
image
HTTPS:
image

域名均加入hosts,证书都是使用OpenSSL生成的,应该没问题。

image

我把部署脚本整理一下发你邮箱,麻烦帮我看看,谢谢!

from blog-example.

quanzaiyu avatar quanzaiyu commented on July 20, 2024

您好,相关的部署脚本我已发送到您的邮箱,麻烦查收一下。

image

from blog-example.

quanzaiyu avatar quanzaiyu commented on July 20, 2024

弄出来了,还需要装一个metallb,云环境比如ECS中是自带了的,但本地还得自己配。

image

from blog-example.

Related Issues (15)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.