Overview
This topic explains the mechanics involved in scaling cloud Helpers automatically using Virtual Machines Scale Sets (VMSSs), for Incredibuild for Windows and Incredibuild for Linux. The process involves these steps:- Create a Virtual Machine Scale Set (one or more).
- For each of the Virtual Machine Scale Sets above, attach a startup script to install Incredibuild.
- For each of the Virtual Machine Scale Sets above, create autoscale rules.
Requirements
To use autoscaling you must have:- An Azure account, with enough permissions.
- Access between your Coordinator and Initiators to the Virtual Network (VNET) where the helpers will run, over all relevant TCP ports (see System Requirements).
- It is required to allow the Cloud Helpers access to the Coordinator via TCP port 32103 (or 31104 if you choose to leave the communication unencrypted).
- You have a working Incredibuild environment, either on-prem or in your VNET.
- You have a network connection between your Coordinator and Initiators to/from your VNET.
- You are experienced with Incredibuild technology.
- You are well versed in managing Azure Virtual Machines.
Create a Virtual Machine Scale Set
The Virtual Machine Scale Set (VMSS) you create will include the details about the image (Windows or Linux), the network requirements for the Helper instances (so they can communicate with the Coordinator and Initiators) and the Virtual Machine size.Incredibuild for Windows
Create the VMSS with the Win2022Datacenter image, and default login credentials. Select the appropriate machine size and authentication method. CopyIncredibuild for Linux
Use the following example to create a startup script for Linux. Make sure you download the Incredibuild release that matches your Coordinator. CopyCreate Autoscale Rules
The autoscale commands allow you to specify when the VMSS will spin up/down virtual machines. The following sample CLI commands instruct the VMSS to spin up a new VM when the load on an existing VM exceeds 50% for 2 minutes, and spin a VM down if the load is below 30% for 2 minutes. CopySet Helper Assignment Priority
To achieve the highest efficiency and save on cloud costs, you need to give on-prem Helpers a lower assignment priority than Helpers that launch in the cloud VPC. A lower priority value means the Coordinator would choose to use the on-prem Helpers over cloud Helpers. The simplest way to do that is to use the Coordinator Manager and set the Helper Assignment Priority of the on-prem Helpers to a lower number assignment priority (the lower the number the higher the priority, that is, lower values mean that the Helper is more likely to be used). See Agent List Actions. Alternatively, the Incredibuild installer includes the option to set the priority during the installation. Set the/AGENT:HELPERASSIGNMENTPRIORITY as described in Silent Installation.