We’re excited to announce that Elastigroup for Azure now supports Jenkins, providing Jenkins users with up to 80% savings on their compute costs. Elastigroup manages the nodes running Jenkins slaves on Azure’s Low-Priority VMs, which provide up to 80% cost savings compared to standard VMs. Combined with Elastigroup’s automated scaling based on the queue of pending jobs in Jenkins, the result is both optimal capacity management and cost efficiency.
How Elastigroup Manages Jenkins for Optimized Cost Efficiency
The Spotinst Jenkins Plugin (1) detects the number of queued jobs and scales Low-Priority VMs as nodes accordingly. (2) Nodes are provisioned across multiple VM types and Regions to optimize savings while still guaranteeing availability. (3) Provisioned nodes run a startup script to connect as Jenkins Slave nodes to the Jenkins Master and immediately start running jobs. (4) Automatically detect and terminate idle nodes.
Getting Started in 3 Easy Steps
Step 1: Create an Elastigroup
Log on to the Spotinst Console with an Azure connected account and create a Spotinst API Access Token. Save it for use in the Jenkins configuration. Create an Elastigroup for the Jenkins Slave nodes to run in. Utilize as many VM types and Regions as possible to maximize availability.
In the Compute tab, under Additional Configurations add the following user-data:
Step 2: Update the Slave Connect Port
The Jenkins Master – Slave connection is based on JNLP protocol.
By default, the Slaves try to connect on a random JNLP port, so the firewall rules need to be reconfigured in order to allow all ports to be open and ensure successful communications from Slave to Master.
To configure a fixed JNLP port for the Jenkins Slaves, navigate to Manage Jenkins >> Global Security>>Agents and set a static TCP port for JNLP agents. Then, configure the network to be available exclusively for this port.
Step 3: Installing the Spotinst Plugin for Jenkins
Log on to the Jenkins console and install the Spotinst Plugin from the available Plugins list.
After installing the plugin, Restart Jenkins.
Navigate to Manage Jenkins >> Configure System, scroll down to the Spotinst section and add the API Token generated in Step 1, along with the appropriate Account ID. Then click on Validate Token to ensure that the token is valid.
Once the Spotinst Token is set, scroll down towards the bottom to the Cloud section, Click on Add a new cloud and select Azure.
In the new parameters available, specify the Elastigroup ID for the Elastigroup created in Step 2 and Idle Minutes Before Termination to determine how long Elastigroup should wait before terminating an idle node.
You’re all set! Spotinst will now manage your Jenkins Slave nodes on Azure, providing you with 80% cost savings and automatically scaling up and down based on pending jobs.
For more on the Spotinst integration with Jenkins and troubleshooting, check out our Jenkins integration tutorial here.
We use technologies like cookies to store and/or access device information. We do this to improve browsing experience and to show (non-) personalized ads. Consenting to these technologies will allow us to process data such as browsing behavior or unique IDs on this site. Not consenting or withdrawing consent, may adversely affect certain features and functions.
Functional
Always active
The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
The technical storage or access that is used exclusively for statistical purposes.The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.