The following process assumes a three-node gateway cluster with each node running on a separate host.

See the Troubleshooting section if you encounter problems.

Spin up nodes

The gateway is available as an Open Virtual Machine Appliance (OVA).

  1. Download the OVA file.

  2. Spin up the VMs from the OVA on the ESXi host.

  3. Log in to each VM with the default credentials provided to you. Make sure you change the password.

    You now have VMs for each node of the cluster.

  4. Set the unique hostname on each node:

     
    
    
            sudo hostnamectl set-hostname <hostname>
            
  5. Add the IP address and hostname of all 3 nodes in etc/hosts file:

     
    
    
            sudo nano /etc/hosts
            

    Example additions to the etc/hosts file:

     10.200.1.1  cluster-node-01
     10.200.1.2  cluster-node-02
     10.200.1.3  cluster-node-03
    

Install MicroK8s

Run the following commands on all nodes.

    

        cd /var/lib/node-manager
        sudo python main.py --install
        

Make sure MicroK8s service is running on all nodes:

    

        sudo microk8s status
        

Join nodes to the cluster

With three gateway nodes running, join them to create a cluster.

Select one of the nodes as your first node in the cluster, called node 1. You do not need to take additional action to add the first node to the cluster.

Join node 2

  1. To add the second node, node 2, to the cluster. Go to node 1 and run:

     
    
    
            microk8s add-node
            
  2. This returns joining instructions:

     
    
    
            microk8s join ip-172-31-20-243:25000/DDOkUupkmaBezNnMheTBqFYHLWINGDbf
            

    If the node you are adding is not reachable with the default interface, use:

     
    
    
            microk8s join 10.1.84.0:25000/DDOkUupkmaBezNnMheTBqFYHLWINGDbf
            microk8s join 10.22.254.77:25000/DDOkUupkmaBezNnMheTBqFYHLWINGDbf
            
  3. Copy the above command and run it on node 2.

     
    
    
            microk8s join ip-172-31-20-243:25000/DDOkUupkmaBezNnMheTBqFYHLWINGDbf
            
  4. Wait for the process to complete on node 2.

Join node 3

To join the third node to the cluster, node 3, repeat the steps you used to join node 2.

To check that the nodes are successfully added, run:

    

        microk8s kubectl get nodes
        

Deploy gateway services on the nodes

With the cluster set up, deploy gateway applications to the cluster.

Enable DNS

Run the following command on one of the nodes to enable DNS:

    

        microk8s enable dns
        

Install Persistent Storage, MetalLB, and Gateway Manager services

  1. Create a folder to download the required files:

     
    
    
            mkdir /var/lib/node-manager/charts
            cd /var/lib/node-manager/charts
            
  2. Pull the required services:

     
    
    
            sudo helm chart pull us-docker.pkg.dev/opsramp-registry/gateway-cluster-charts/gateway-extras:1.0.0
            sudo helm chart pull us-docker.pkg.dev/opsramp-registry/gateway-cluster-charts/traefik:1.0.0
            sudo helm chart pull us-docker.pkg.dev/opsramp-registry/gateway-cluster-charts/gateway-manager:0.9.13
            sudo helm chart pull us-docker.pkg.dev/opsramp-registry/gateway-cluster-charts/kubernetes-dashboard:0.9.6
            
  3. Export the required services:

     
    
    
            sudo helm chart export us-docker.pkg.dev/opsramp-registry/gateway-cluster-charts/gateway-extras:1.0.0
            sudo helm chart export us-docker.pkg.dev/opsramp-registry/gateway-cluster-charts/traefik:1.0.0
            sudo helm chart export us-docker.pkg.dev/opsramp-registry/gateway-cluster-charts/gateway-manager:0.9.13
            sudo helm chart export us-docker.pkg.dev/opsramp-registry/gateway-cluster-charts/kubernetes-dashboard:0.9.6
            
  4. Specify the details in the values.yaml file to configure the Storage type, NFS IP Address, NFS Path, and MetalLB IP details. Run:

     
    
    
            sudo nano /var/lib/node-manager/charts/gateway-extras/values.yaml
            
  5. Enter the storageType, nfsServerIp, nfsServerPath, and metallbIp as shown in the example:

     
    
    
            storageType: &storageType nfs
            localStoragePath: &localStoragePath /var/gateway/storage
            nfsServerIp: &nfsServerIp 172.25.251.89
            nfsServerPath: &nfsServerPath /srv/nfsdemo
            metallbIp: &metallbIp 172.25.252.100/32  #Use ip/32 format
            
  6. Install Storage, MetalLB, Gateway Manager and Kubernetes dashboard, including specifying a password:

     
    
    
            helm install gateway-extras /var/lib/node-manager/charts/gateway-extras
            helm install traefik /var/lib/node-manager/charts/traefik
            helm install gateway-manager /var/lib/node-manager/charts/gateway-manager -f /var/lib/node-manager/charts/gateway-manager/cluster.yaml --set secrets.defaultPassword=Pass@1234 --debug
            

    Kubernetes dashboard is used for troubleshooting, and not mandatory:

     
    
    
            helm install kubernetes-dashboard /var/lib/node-manager/charts/kubernetes-dashboard --namespace kubernetes-dashboard --create-namespace --debug
            
  7. Log in to the Gateway Manager to register the gateway.

    Open a web browser and go to https://<IPAddress>. Use the IP address assigned to MetalLB and log in with the password provided during Gateway Manager installation.

Register the Gateway Cluster

Log in to Gateway Manager to register the cluster gateway:

  1. Go to Setup > Management Profiles.
  2. Create a new management profile and copy the activation token.
  3. Enter the activation token into the Gateway Manager.

Wait for cluster registration to complete. You should see connected in the UI management profile status.