Information Technology Reference
In-Depth Information
Run one of the following commands to add a node entry. Following are the commands we
ran on our machine. If you used an IP address other than 192.168.33.35 , make sure it
matches when you run the command.
Linux/Mac OS X:
$ sudo sh -c "echo '192.168.33.37 node-centos65.vagrantup.com' >> /etc/hosts"
Windows Command Prompt:
> echo 192.168.33.37 node-centos65.vagrantup.com >> \
%WINDIR%\System32\Drivers\Etc\Hosts
Windows PowerShell:
PS> ac -Encoding UTF8 $env:windir\system32\drivers\etc\hosts \
"192.168.33.37 node-centos65.vagrantup.com"
You also need to kitchen login to the node and configure the local host database on the
node to provide it the name of the server where you will run chef-client . Once this is com-
plete, exit back out to your host prompt. As mentioned before, in production, you'd just
make sure the DNS was configured with these hostnames before installing Chef Server and
any nodes:
$ kitchen login node-centos65
Last login: Fri Jul 4 14:48:27 2014 from 10.0.2.2
Welcome to your Packer-built virtual machine.
[vagrant@node-centos65 ~]$ sudo sh -c "echo \
'192.168.33.36 default-centos65.vagrantup.com' >> /etc/hosts"
[vagrant@node-centos65 ~]$ exit
logout
Connection to 127.0.0.1 closed.
Run the following command to bootstrap your node:
$ knife bootstrap --sudo --ssh-user vagrant --ssh-password \
vagrant --no-host-key-verify node-centos65.vagrantup.com
Connecting to node-centos65.vagrantup.com
Search WWH ::




Custom Search