创建部署问题时,请参考下面模板,你提供的信息越多,越容易及时获得解答。如果未按模板创建问题,管理员有权关闭问题。
确保帖子格式清晰易读,用 markdown code block 语法格式化代码块。
你只花一分钟创建的问题,不能指望别人花上半个小时给你解答。
操作系统信息
例如:虚拟机,Centos7.5,4C/8G
Kubernetes版本信息
Client Version: version.Info{Major:“1”, Minor:“22”, GitVersion:“v1.22.1”, GitCommit:“632ed300f2c34f6d6d15ca4cef3d3c7073412212”, GitTreeState:“clean”, BuildDate:“2021-08-19T15:45:37Z”, GoVersion:“go1.16.7”, Compiler:“gc”, Platform:“linux/amd64”}
Server Version: version.Info{Major:“1”, Minor:“22”, GitVersion:“v1.22.10”, GitCommit:“eae22ba6238096f5dec1ceb62766e97783f0ba2f”, GitTreeState:“clean”, BuildDate:“2022-05-24T12:50:52Z”, GoVersion:“go1.16.15”, Compiler:“gc”, Platform:“linux/amd64”}
KubeSphere版本信息
v3.3.0 在已有K8s上安装
问题是什么
kind: Ingress
apiVersion: networking.k8s.io/v1
metadata:
name: demo-router
namespace: demo
annotations:
kubesphere.io/creator: admin
nginx.ingress.kubernetes.io/ssl-redirect: 'false'
spec:
rules:
- host: demo.dev
http:
paths:
- path: /
pathType: ImplementationSpecific
backend:
service:
name: demo-dev
port:
number: 80

在本地配置好hosts后,访问时被重定向到https,响应码307
