WORKLOAD AUTOMATION COMMUNITY
  • Home
  • Blogs
  • Forum
  • Resources
  • Events
    • IWA 9.5 Roadshows
  • About
  • Contact
  • What's new

How to Automate Configuration Management with the Chef in Workload Automation

5/11/2020

0 Comments

 
Picture
Let us understand Configuration Management this way – assume you must dispose a software over hundreds of machines. This software can be an operating system or a code or it can be an update of a currently running software. It is possible for you to do this task manually, but what results if you have to complete this assignment overnight due to any important mass event taking place at your organization next day in which heavy traffic is foreseen. Even if you were prepared to do this by-hand there is a high chance of recurring errors on your big day. In such a case, returning to the previous stable version, will not be possible to do manually with ease.
​
To solve this problem, Configuration Management was introduced. By using Configuration Management tools like Chef, we can achieve this.
Picture
In order to let Workload Automation users make the most out of Chef, we have added two plugins on the Automation Hub, the catalogue of Workload Automation integrations to automate more and better.

We have divided two major functionalities of Chef into two Chef plugins, they are as follows,
  • ChefBootstrap
The  ChefBootstrap  plugin enables you to schedule and monitor the installation of  Chef client on one or more nodes, you can also define your Chef serve authentication credentials and register the nodes to make them communicate with the Chef server.

  • ChefRunlist
The  ChefRunlist  plugin enables you to schedule and monitor the execution of cookbooks and recipes configured on a  Chef server on the nodes. 
 
Now let us see how these both plugin works.
​
Prerequisite for each plugin is that you should have chef workstation setup and chef server configuration in your agent to connect your chef server.  
 
ChefBootstrap:
How to bootstrap a node using ChefBootstrap plugin: 
 
Log  in to the  Dynamic Workload Console  and  open the  Workload Designer.  Choose to create a new job and  select  “ChefBootstrap” job type in  the  Cloud section. 
Picture
Establishing connection to the Chef server: 
 
In the connection tab specify the repository path of the configuration and pem files in the Repo path field to let workload Automation interact with chef server and click Test Connection. A confirmation message is displayed when the connection is established. 
 
Note: The configuration file should have: 
Node_name = Organization name of the chef server  
client_key = Location of the pem path  
chef_server_url = Chef server url  
chef_license 'accept' = This has to be added only if you are using chef-client version > or =15 ​
Picture
Bootstrap a Node: 
 
In Action tab specify the node machine details which you want to bootstrap. A node could be any physical, virtual, or cloud device.  
Provide the host name of the node. Provide either a password or path to the file in which you stored your SSH private key and a node name to establish a connection to node machine. 
Click Test connection to verify that the connection to the node. A confirmation message is displayed when the connection is established. ​
Picture
Submitting your job:
​ 
It is time to Submit your job into the current plan. You can add your job to the job stream that automates your business process flow. Select the action menu in the top-left corner of the job definition panel and click on Submit Job into Current Plan. A confirmation message is displayed, and you can switch to the Monitoring view to see what is going on. 
 ​
Picture
Track/Monitor your Job: 

You can also easily monitor the submitted job in WA through navigating to “Monitor Workload” page. ​
Picture
Select the job and click on job log option to view the logs of the ChefBootstrap job. 
Here, you can see that the Chef-client is installed in the node and connection is established successfully between Chef server and the node.

 ​
Picture
Extra Information: 
 
You can see that there are few “Extra properties” provided by the plug-in which you can use these variables for the next job submission. ​
Picture
ChefRunlist: 
 
How to add recipes to a node using ChefRunlist plugin: 
 
Log in to the Dynamic Workload Console and open the Workload Designer. Choose to create a new job and select “ChefRunlist” job type in the Cloud section. ​
Picture
Establishing connection to the Chef server: 
 
In the connection tab specify the repository path of the configuration and pem files in the Repo path field to let workload Automation interact with chef server and click Test Connection. A confirmation message is displayed when the connection is established. 
Note: The configuration file should have: 
Node_name = Organization name of the chef server  
client_key = Location of the pem path  
chef_server_url = Chef server url  
chef_license 'accept' = This has to be added only if you are using chef-client version > or =15 ​
Picture
Add Recipes to a Node: 
 
In Action tab specify the recipes that needs to be executed on the selected nodes.
Picture
Click on the search button under Recipes to lookup the list of recipes from the chef server. Multi select the recipes which you want to apply on nodes.
Picture
Submitting your job:
 ​ 
It is time to Submit your job into the current plan. You can add your job to the job stream that automates your business process flow. Select the action menu in the top-left corner of the job definition panel and click on Submit Job into Current Plan. A confirmation message is displayed, and you can switch to the Monitoring view to see what’s going on. ​
Picture
Track/Monitor your Job: 

You can also easily monitor the submitted job in WA through navigating to “Monitor Workload” page. ​
Picture
Select the job and click on job log option to view the logs of the ChefRunlist job. 
Here, you can see that the selected recipes are applied to the selected nodes.

Picture
Extra Information: 
You can see that there are few “Extra properties” provided by the plug-in which you can use these variables for the next job submission. ​
Picture
Therefore, ChefBootstrap and ChefRunlist plugins in Workload Automation is a best fit for those who are looking for complete automation of the configuration management.

Are you curious to try out the Chef plugin? Download the integrations from the Automation Hub and get started or drop a line at santhoshkumar.kumar@hcl.com.

Author's BIO
Picture
Dharani Ramalingam, Senior Java Developer at HCL Technologies

Works as a Plugin Developer in Workload Automation. Technology enthusiast who loves to learn new tools and technologies. Acquired skills on Java, Spring, Spring Boot, Microservices, ReactJS,  NodeJS, JavaScript, Hibernate.

View my profile on LinkedIn
Picture
Arka Mukherjee, Quality Analyst at HCL Technologies

Working as Quality Analyst for the Workload Automation team in HCL Software, Bangalore. Worked both in manual and automation test scenarios across various domains
View my profile on LinkedIn
Picture
Rabic Meeran K, Technical Specialist at HCL Technologies

Responsible for developing integration plug-ins for Workload Automation. Hands-on with different programing languages and frameworks like JAVA, JPA, Spring Boot, Microservices, MySQL, Oracle RDBMS, Ruby on Rails, Jenkins, Docker, AWS, C and C++.
0 Comments

Your comment will be posted after it is approved.


Leave a Reply.

    Archives

    January 2021
    December 2020
    November 2020
    October 2020
    September 2020
    August 2020
    July 2020
    June 2020
    May 2020
    April 2020
    March 2020
    January 2020
    December 2019
    November 2019
    October 2019
    August 2019
    July 2019
    June 2019
    May 2019
    April 2019
    March 2019
    February 2019
    January 2019
    December 2018
    November 2018
    October 2018
    September 2018
    August 2018
    July 2018
    June 2018
    May 2018
    April 2018
    March 2018
    February 2018
    January 2018
    December 2017
    November 2017
    October 2017
    September 2017
    August 2017
    July 2017
    June 2017
    May 2017

    Categories

    All
    Analytics
    Business Applications
    Cloud
    DevOps
    Monitoring & Reporting

    RSS Feed

www.hcltechsw.com
About HCL Software 
HCL Software is a division of HCL Technologies (HCL) that operates its primary software business. It develops, markets, sells, and supports over 20 product families in the areas of DevSecOps, Automation, Digital Solutions, Data Management, Marketing and Commerce, and Mainframes. HCL Software has offices and labs around the world to serve thousands of customers. Its mission is to drive ultimate customer success with their IT investments through relentless innovation of its products. For more information, To know more  please visit www.hcltechsw.com.  Copyright © 2019 HCL Technologies Limited
  • Home
  • Blogs
  • Forum
  • Resources
  • Events
    • IWA 9.5 Roadshows
  • About
  • Contact
  • What's new