mirror of
https://github.com/alibaba/higress.git
synced 2026-05-22 19:57:29 +08:00
69 lines
1.3 KiB
YAML
69 lines
1.3 KiB
YAML
apiVersion: gateway.networking.k8s.io/v1beta1
|
|
kind: GatewayClass
|
|
metadata:
|
|
name: istio
|
|
spec:
|
|
controllerName: higress.io/gateway-controller
|
|
---
|
|
apiVersion: gateway.networking.k8s.io/v1beta1
|
|
kind: Gateway
|
|
metadata:
|
|
name: gateway
|
|
namespace: istio-system
|
|
spec:
|
|
addresses:
|
|
- value: istio-ingressgateway
|
|
type: Hostname
|
|
gatewayClassName: istio
|
|
listeners:
|
|
- name: default
|
|
hostname: "*.domain.example"
|
|
port: 80
|
|
protocol: HTTP
|
|
allowedRoutes:
|
|
namespaces:
|
|
from: All
|
|
---
|
|
apiVersion: gateway.networking.k8s.io/v1beta1
|
|
kind: HTTPRoute
|
|
metadata:
|
|
name: mixed-parent-ref-validity
|
|
namespace: default
|
|
spec:
|
|
parentRefs:
|
|
# valid refs
|
|
- name: gateway
|
|
namespace: istio-system
|
|
port: 80
|
|
- kind: ServiceEntry
|
|
group: networking.istio.io
|
|
name: egress
|
|
# invalid refs
|
|
- name: gateway
|
|
namespace: istio-system
|
|
port: 1234 # invalid port
|
|
- group: ''
|
|
kind: Service # service does not exist
|
|
name: random
|
|
namespace: nonexistent
|
|
rules:
|
|
- backendRefs:
|
|
- name: httpbin
|
|
port: 80
|
|
weight: 1
|
|
---
|
|
apiVersion: networking.istio.io/v1
|
|
kind: ServiceEntry
|
|
metadata:
|
|
name: egress
|
|
namespace: default
|
|
spec:
|
|
hosts:
|
|
- "google.com"
|
|
ports:
|
|
- number: 80
|
|
name: http
|
|
protocol: HTTP
|
|
- number: 443
|
|
name: tls
|
|
protocol: TLS |