Problem: you have a Windows Cluster and you want to do deployments with Octopus Deploy. Therefore you need to run an Octopus Tentacle on the cluster nodes. The problem is that an Octopus Tentacle isn’t cluster-aware. In this post I’m going to explain how to solve this problem.
Clustering the Octopus Tentacle
Assuming you have a 2 node cluster, install the Octopus Tentacle on both nodes just like you would do on a non-clustered machine. Then start the Failover Cluster Manager and go to ‘Roles’:
(Sensitive information like the owner node and IP address is removed in this image, just as it is in the next images)
In the High Availability Wizard, Select Role tab, click ‘Generic Service’:
In the Select Service tab, click ‘OctopusDeploy Tentacle’:
In the Client Access Point tab, enter a name and an IP address (if you’re not a domain/network admin, you probably need some help from the person who is):
Skip the ‘Select Storage’ tab, you don’t need shared storage for this. In the Replicate Registry Settings, Add Registry Key ‘Software\Octopus’:
Confirm and Configure High Availability and your Octopus Tentacle is clustered!
If your newly created role doesn’t come online, it’s probably because it isn’t (properly) added as a server in the domain. If you are not the Domain Admin, talk to the person who is to fix this.
Generate a New Certificate and import it on both machines
Because the Octopus Tentacles on both machines have different thumbprints and use different certificates, you need to create a new certificate on one of the machines and import it on both. This way, if a failover occurs, the Octopus Tentacle keeps running with the same thumbprint and the Octopus Server will recognize it as the same tentacle. Here’s how to create a new certificate and import it (running Octopus Tentacle 3.2.21). Open a command prompt on one of the machines, go to the Octopus Tentacle folder and stop the tentacle (tentacle service –stop). Then issue the command ‘tentacle.exe new-certificate -e MyFile.txt’:
On the same machine, import the certificate by issuing the command ’tentacle.exe import-certificate –instance “Tentacle” -f “MyFile.txt“ –console’:
Start the tentacle again (tentacle service –start). Copy the file with the certificate to your other machine, stop the tentacle and do the same import. Test by moving your newly created Failover Cluster Tentacle between the nodes and also have a look in the Octopus Tentacle Manager on each node (are the thumbprints the same on each node?). That’s it, you’re all set. Now you can add the newly created role as a machine on the Octopus Server and do deployments to your cluster!