1. Install chef-db
|
ChefDK contains:
- An early version of a brand new command-line tool, chef, that aims to streamline Chef workflow, starting with new generators.
- The well-known cookbook dependency manager Berkshelf 3.0.
- The Test Kitchen integration testing framework.
- ChefSpec, which makes unit testing cookbooks a breeze.
- Foodcritic, a linting tool for doing static code analysis on cookbooks.
- All of the Chef tools you’re already familiar with: Chef Client, Knife, Ohai and Chef Zero.
chefdb’s file structure after installation
Verification
After installation, verify all the component:
|
Componnet | Description |
---|---|
berkshelf | 管理cookbook |
test-kitchen | 测试cookbook框架 |
chef-client | |
chef-dk | Chef开发kit |
chefspec | |
rubocop | |
fauxhai | |
knife-spork | |
kitchen-vagrant | |
package installation | |
openssl | 安全机制SSL |
Summary
安装结束,验证所有component安装成功.
2. Install and configure the chef-server
在chef主页注册hosted chef server, 之后下载starter kit
下载starter kit
Download start kit, chef-repo folder in the size of 9.5 KB
locate the chef-repo
Contains chef configuration files.
|
Verification
|
验证通过显示list
Summary
配置好和server的connection结束
3. Install and configure a node
在开启了SSH的情况下用knife配置node
安装命令
deploy node divide into 4 steps:
- install the client(install chef-12.4.1-1.dmg above)
- start chef client creating a new client identity
- Synchronizing Cookbooks and Compile it
- Run handlers
Verification
Pay attention to the current folder, as the knife will use the pem file for validation
The view after loginned the chef manager:
Summary
Use the workstation or the server to monitor the node. I can’t find the chef-client in the node computer.
4. Delete the node
|
After the delete, the client still can show the that node information.
Verification
But there is no such node in the server.
Summary
It is quite easy to delte the node. But pay an attention to the info. The node information is node deleted completely from ther server.