我试图通过istio访问OpenFaaS,其中包含了网关和虚拟服务。
我需要为OpenFaaS创建一个单独的端点,例如:"http://istio_ingress_Loadbalancer/openfaas" -这应该会给我一个OpenFaaS UI。
有没有人可以帮助我,因为我很难访问这个网站?下面是我为网关和虚拟服务编写的代码。
apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
name: openfaas-gateway
spec:
selector:
istio: ingressgateway
servers:
- port:
number: 80
name: http
protocol: HTTP
hosts:
- "*"
---
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
name: openfaas-vs
spec:
hosts:
- "*"
gateways:
- openfaas-gateway.openfaas.svc.cluster.local
http:
- match:
- uri:
prefix: /openfaas
route:
- destination:
host: gateway.openfaas.svc.cluster.local
port:
number: 8080发布于 2021-05-28 03:23:59
在Gateway yaml文件中添加名称空间属性。在VirtualService yaml文件中使用以下格式引用网关:/ https://istio.io/latest/docs/reference/config/networking/virtual-service/#VirtualService
https://stackoverflow.com/questions/67699307
复制相似问题