The Istio gateway and virtualservice settings are
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: demo-service
spec:
hosts:
- "*"
gateways:
- demo-gateway
http:
- route:
- destination:
host: demo-service
port:
number: 80
weight: 100
match:
- uri:
prefix: /
---
apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
name: demo-gateway
spec:
selector:
istio: ingressgateway
servers:
- port:
number: 443
name: https-443
protocol: HTTPS
tls:
mode: SIMPLE
credentialName: "tls-secret"
hosts:
- "demo.my-org.com"
---
apiVersion: install.istio.io/v1alpha1
kind: IstioOperator
metadata:
name: default
spec:
meshConfig:
defaultConfig:
tracing:
sampling: 50
I have deployed a web service before, it’s
$ kubectl get svc
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
demo-service NodePort 172.10.123.111 <none> 80:30898/TCP 10m
After deployment, when access browser, it showed 502 Bac Gateway. From the istio ingressgateway’s log, I found some message as
$ kubectl get pods -n istio-system -o name -l istio=ingressgateway | sed 's|pod/||' | while read -r pod; do kubectl logs "$pod" -n istio-system; done
......
2022-01-16T01:12:23.729756Z info xdsproxy connected to upstream XDS server: istiod.istio-system.svc:15012
......
[2022-01-16T01:15:22.192Z] "- - -" 0 NR filter_chain_not_found - "-" 0 0 0 - "-" "-" "-" "-" "-" - - 10.148.53.210:8443 10.148.55.162:13820 - -
Is it necessary also to set EnvoyFilter
? How to diagnose and resolve the issue?
I deployed an AuthorizationPolicy
before but have deleted it. Is there a way to check this kind by cli?