I'm currently setting up a POC spinnaker pipeline to deploy to a kubernetes cluster.
Experimenting with spinnaker's red/black strategy, i've noticed that it does not behave as i expect it to. I expect it to guarantee that only 1 version gets traffic with the following steps:
- deploy black server group (kubernete's replicaset) & ensure it's healthy
- reroute the traffic of the service to the black server group by updating the load balancer's targets
- disable the red server group
But in reality, at least when using it with kubernetes, step 2 here seems to map to several steps:
- add black targets to the load balancer
- remove red targets from the load balancer
Therefore, i get 2 versions serving traffic for a minute here.
To my understanding, blue green can be achieved in kubernetes by updating the service (load balancer) 's pods selector, so i'm confused as for why spinnaker's kubernetes driver does not seem to leverage this.
Can anybody help me see what i'm missing here ?
Thanks