Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Configuring istio gateway on gcp vm to connect to classic load balancer

Hi community,

I have stuck in this for past few days let me start by explaining my setup.

I have provisioned 3 vms 1 master and 2 workers. Installed rke2 on master and using rke2-agent connected 2 worker nodes. Next I installed Rancher and gave it a domain name which points to the master vm external ip. Domain is in Route 53.

Next I have provisioned a load balancer with instance group containing the 2 worker nodes. Load balancer is of type Classic Proxy SSL Network Load balancer and uses port 443 for health-check and everything. 

Next I have installed helm and setup istio using helm and provided the load balancer ip in the values.yaml file and after this I can see that the istio is configured correctly and everything seems good. The load balancer is showing both workers healthy. And when I do
$ kubectl describe istio-ingressgateway -n istio-system
I am getting the IP of the load balancer I have given. 

Next I have made a domain name using Route 53 to point to the load balancer ip. Now to test the whole setup I did

helm repo add sikalabs <PII removed by staff>

helm pull sikalabs/hello-world

$ helm install hello-world ./ -n wordpress -f values.yaml
NAME: hello-world
LAST DEPLOYED: Mon Oct  7 11:10:48 2024
NAMESPACE: wordpress
STATUS: deployed
REVISION: 1
TEST SUITE: None

Next I made a Virtual service and gateway which looks like this:

 

 

apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
  name: wordpress-gateway
  namespace: istio-system
spec:
  selector:
    istio: ingressgateway
  servers:
  - port:
      number: 80
      name: http
      protocol: HTTP
    hosts:
    - "<my-domain-name>"
---
apiVersion: networking.istio.io/v1alpha3
kind: VirtualService
metadata:
  name: wordpress-vs
  namespace: wordpress
spec:
  hosts:
  - "<my-domain-name>"
  gateways:
  - istio-system/wordpress-gateway
  http:
  - match:
    - uri:
        prefix: "/wordpress"  # Match the /wordpress path
    rewrite:
      uri: "/"  # Rewrite the path so that WordPress sees the root path
    route:
    - destination:
        host: hello-world
        port:
          number: 80

 

 

But now when I go to the browser and run <my-domain-name>/wordpress all I am getting is

This page isn’t working

<my-domain-name> didn’t send any data.

ERR_EMPTY_RESPONSE

Please help me solve this issue.
0 0 69
0 REPLIES 0
Top Labels in this Space