I am trying to make use of keepalived with Rancher’s load balancer to have floating VIPs available. The problem seems to be that when I tell the Load Balancer to select the VIP address, the page submits fine, but the address does not get assigned to the LB.
I am using Cattle on Rancher Server 1.6.3.
I have 3 hosts for running my back-end services, and 2 hosts for running load balancers. I am using https://hub.docker.com/r/oberthur/docker-keepalived/ and I have it configured to run on all hosts that have the label role=loadbalancer. This part works fine, as I can see that both of the VIPs are running on one of the two LB hosts.
[rancher@prod-ros-cattle-lb-01 ~]$ ip addr | grep 126
inet 10.30.126.81/26 scope global eth0 < Rancher OS eth0
inet 10.30.126.72/32 scope global eth0 < keepalived VIP1 for service 1
inet 10.30.126.83/32 scope global eth0 < keepalived VIP2 for service 2
When I edit the service for one of the load balancers, I click the link for “Show host IP address options.” and in the box, I enter 10.30.126.72, and click “Edit” to save the configuration. The page goes back to the Stack page. If I click the button to show the yaml, I see this for the rancher-compose:
version: '2'
services:
Jenkins:
scale: 1
start_on_create: true
Jenkins-LB:
start_on_create: true
lb_config:
certs: []
default_cert: Jenkins
port_rules:
- priority: 1
protocol: https
service: Jenkins
source_port: 443
target_port: 8080
health_check:
healthy_threshold: 2
response_timeout: 2000
port: 42
unhealthy_threshold: 3
initializing_timeout: 60000
interval: 2000
reinitializing_timeout: 60000
There is no place in the configuration where it shows the IP address that I specified. When I look at the Load Balancer in the UI, it looks like it was saved because I see “To: Jenkins Ports: 10.30.126.72:443/tcp”. But when I hover over the link, the actual URL is https://10.30.126.81, instead of 72 so it looks like it is using the host IP and not the VIP that I specified.
Is this a bug, or is this not a supported configuration?