The following will bootstrap a new chef node:
knife bootstrap <ip> -i <key> --ssh-user <ssh_user> --sudo -E <environment> --run-list 'recipe[<recipe_name>]' -N <node_name>
where:
- ip is the ip of the machine to bootstrap;
- key is the ssh key used to connect to the machine;
- environment is the environment type, i.e.
staging
; - recipe_name is the recipe name to use;