将节点添加到厨师服务器

时间:2021-02-03 20:39:54

标签: chef-infra

我正在尝试使用 Knife bootstrap -o winrm 192.168.0.122 -x Administrator -p '' --node-name node1 添加具有 Windows 10 作为操作系统的节点

但它抛出警告无法验证管理员到 192.168.0.122 - 尝试密码验证 输入@ip-address 的密码。节点基本上就是一个虚拟机

1 个答案:

答案 0 :(得分:0)

使用 chef-client 命令自动添加节点。在 Linux 中,它将是(例如):chef-client -j /etc/chef/first-boot.json

对于 Windows,它应该是一个类似的过程。文档说明:

On Microsoft Windows machines: The batch file that is derived from the 
windows-chef-client-msi.erb bootstrap template executes the chef-client binary 
with a set of initial settings stored within first-boot.json on the node. 
first-boot.json is generated from the workstation as part of the initial knife 
bootstrap subcommand.