Hi,
I’m trying to setup Octopus deploy through our Netscaler load balancer, and I’m having some issues, that the rolling deployment scenario might be to limited to achieve. This is a question/discussion on how to best achieve this.
In netscaler (the load balancer) - I’m disabling just one servicegroup (i.e. one specific port for a service) meaning that the rest of the server is operational when I’m deploying the update.
We have a different number of servers that are serving requests (ranging from 2 - 12 servers)
IE the QA environment often have 2-3 load balanced servers.
Producation environment ranges from 2-12 servers serving load balanced requests.
With a rolling deployment you have to specify how many servers you take out at a time.
Scenario (non-breaking changes)
a rolling deployment, taking out 1 server, updating it, putting it back in, taking the next one out, will most likely work fine.
Scenario (breaking changes i.e. meaning I can’t have old and new code running at the same time, it’s either/or)
1)
In this scenario, I need to find out how many servers are running the code (haven’t found this anywhere) i.e listing out which servers have a role running on it. Is this possible, through powershell? IE QA has 2, PROD has 12 servers.
2)
if it’s 2 servers, a rolling deployment of 1 needs to be set, while if it’s 12, then a rolling deployment of 6 needs to be set.
is it possible to set this value run-time in a rolling deployment?
3)
After I have determined how many servers i need to take out of the load balancing, I will have my powershell ask which servers are in the servicegroup in Netscaler, and disable half of these, then for the next step of the deployment take out, update the next batch of servers.
Any advice on how to best achieve this through Octopus?
If i’m not able to access which roles are running on the servers, determining which servers are running the, I will end up with a hardcoded octopus deploy, which will have to be manually updated each time we remove or add a server
role.
Ideally this would be nice and dynamic, as I’m having approximately 30 packages/deployments that are load balanced,
and the effort to maintain these would take a lot of time.
Looking forward to hear if anyone have any ideas on how to do this, or how you solved your load balanced deployments.
Best regards,
Bjørn