Chef is a configuration management and automation platform from Opscode. Chef used to automate, test and replicate infrastructure with ease.
Chef available in two format
1 Chef – Solo
a Used to install, configure and manage the packages on single environment
2 Chef - client and server configuration
a Chef – Server will be used
b Chef – Client will deployed on linux/windows machine and configured with server
How to Use Chef – Client and server
Setup Chef Server
1 Download the latest Chef server core
2 Install the server
3 Run the chef-server-ctl command to start the Chef server services
4 Create a User and Organization to link your Chef server with workstations and nodes
Workstations (Client)
Chef workstation is used create and configure any recipes, cookbooks, attributes, and other changes made to Chef Configurations
1 Download the latest Chef Development Kit for Windows/Linux
2 Install ChefDK (based on DK you downloaded)
3 Generate the chef-repo
a For Linux - mkdir .chef
4 Navigate/Move to the newly-created directory (/.chef)
5 Add the RSA Private Keys (You can download same from chef website)
a https://manage.chef.io/login
b Open the Chef management console.
c Click Policy.
d Click Clients.
e Click Create.
f Copy the private key or download and save the private key locally
6 Generate knife.rb
7 Create a knife configuration file by navigating to ~/chef-repo/.chef folder and create a file named knife.rb
8 Add following details into file and save
log_level :info
log_location STDOUT
node_name 'username'
client_key '~/chef-repo/.chef/username.pem'
validation_client_name 'shortname-validator'
validation_key '~/chef-repo/.chef/shortname.pem'
chef_server_url 'https://123.45.67.89/organizations/shortname'
syntax_check_cache_path '~/chef-repo/.chef/syntax_check_cache'
cookbook_path [ '~/chef-repo/cookbooks' ]
Node (Client)
chef-client will be run from node system.
The chef-client checks the current configuration of the node against the recipes and policies stored in the Chef server and brings the node up to match.
The process begins with the chef-client checking the node’s run list, loading the cookbooks required, then checking and syncing the cookbooks with the current configuration of the node.
Cookbooks
Cookbooks are the main component of configuring nodes on a Chef infrastructure. Cookbooks are comprised of recipes, metadata, attributes, resources, templates, libraries,
Recipes
Recipes are the fundamental part of cookbooks
Recipes are written in Ruby and contain information in regards to everything that needs to be run, changed, or created on a node
Attributes
Attributes define specific values about a node and its configuration
6 comments:
Chef is a worth learning as it is a great tool to automate, brings its expertise in DevOps into customer companies. The Information Provided By Your Blog is Useful for me and Other DevOps Candidates. Thanks a lot
Best Regards,
CourseIng - DevOps Training in Hyderabad
Awesome.. You have clearly explained.it is very simple to understand. it's very useful for me to know about new things...Keep posting.Thank You…For more information visit: devops online training
Thanks for sharing this post.
Full Stack Training in Chennai | Certification | Online Training Course| Full Stack Training in Bangalore | Certification | Online Training Course | Full Stack Training in Hyderabad | Certification | Online Training Course | Full Stack Developer Training in Chennai | Mean Stack Developer Training in Chennai | Full Stack Training | Certification | Full Stack Online Training Course
Really very happy to say, your post is very interesting to read. I never stop myself to say something about it on QA hint You’re doing a great job. Keep it up.
DevOps Training in Chennai
DevOps Online Training in Chennai
DevOps Training in Bangalore
DevOps Training in Hyderabad
DevOps Training in Coimbatore
DevOps Training
DevOps Online Training
very informative.Thanks for posting.
DevOps classes in Pune
Post a Comment