summaryrefslogtreecommitdiff
path: root/chef/distro/common/man/man1/knife-bootstrap.1
blob: 753ae8bfa7e054c05538d1885fb429d6565f5205 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
.\" generated with Ronn/v0.7.3
.\" http://github.com/rtomayko/ronn/tree/0.7.3
.
.TH "KNIFE\-BOOTRAP" "1" "April 2011" "Chef 0.10.0.beta.8" "Chef Manual"
.
.SH "NAME"
\fBknife\-bootrap\fR \- Install Chef Client on a remote host
.
.SH "SYNOPSIS"
\fBknife\fR \fBbootstrap\fR \fI(options)\fR
.
.TP
\fB\-i\fR, \fB\-\-identity\-file IDENTITY_FILE\fR
The SSH identity file used for authentication
.
.TP
\fB\-N\fR, \fB\-\-node\-name NAME\fR
The Chef node name for your new node
.
.TP
\fB\-P\fR, \fB\-\-ssh\-password PASSWORD\fR
The ssh password
.
.TP
\fB\-x\fR, \fB\-\-ssh\-user USERNAME\fR
The ssh username
.
.TP
\fB\-\-prerelease\fR
Install pre\-release Chef gems
.
.TP
\fB\-r\fR, \fB\-\-run\-list RUN_LIST\fR
Comma separated list of roles/recipes to apply
.
.TP
\fB\-P\fR, \fB\-\-ssh\-password PASSWORD\fR
The ssh password
.
.TP
\fB\-x\fR, \fB\-\-ssh\-user USERNAME\fR
The ssh username
.
.TP
\fB\-\-template\-file TEMPLATE\fR
Full path to location of template to use
.
.TP
\fB\-\-sudo\fR
Execute the bootstrap via sudo
.
.TP
\fB\-d\fR, \fB\-\-distro DISTRO\fR
Bootstrap a distro using a template
.
.P
Performs a Chef Bootstrap on the target node\. The goal of the bootstrap is to get Chef installed on the target system so it can run Chef Client with a Chef Server\. The main assumption is a baseline OS installation exists\. This sub\-command is used internally by some cloud computing server create commands and the others will be migrated in a future version of Chef\.
.
.P
The bootstrap sub\-command supports supplying a template to perform the bootstrap steps\. If the distro is not specified (via \fB\-d\fR or \fB\-\-distro\fR option), an Ubuntu 10\.04 host bootstrapped with RubyGems is assumed\. The \fBDISTRO\fR value corresponds to the base filename of the template, in other words \fBDISTRO\fR\.erb\. A template file can be specified with the \fB\-\-template\-file\fR option in which case the \fBDISTRO\fR is not used\. The sub\-command looks in the following locations for the template to use:
.
.IP "\(bu" 4
\fBbootstrap\fR directory in the installed Chef Knife library\.
.
.IP "\(bu" 4
\fBbootstrap\fR directory in the \fB$PWD/\.chef\fR\.
.
.IP "\(bu" 4
\fBbootstrap\fR directory in the users \fB$HOME/\.chef\fR\.
.
.IP "" 0
.
.P
The default bootstrap templates are scripts that get copied to the target node (FQDN)\. As of Chef 0\.9\.8, the following distros are supported:
.
.IP "\(bu" 4
centos5\-gems
.
.IP "\(bu" 4
fedora13\-gems
.
.IP "\(bu" 4
ubuntu10\.04\-gems
.
.IP "\(bu" 4
ubuntu10\.04\-apt
.
.IP "" 0
.
.P
The gems installations will use RubyGems 1\.3\.6 and Chef installed as a gem\. The apt installation will use the Opscode APT repository\. The RubyGems installation requires installing gems with native extensions, so development related packages (ruby\-dev, build\-essential) are installed\. These are not installed with the apt installation, as native extensions are already compiled in the required packages\.
.
.P
In addition to handling the software installation, these bootstrap templates do the following:
.
.IP "\(bu" 4
Write the validation\.pem per the local knife configuration\.
.
.IP "\(bu" 4
Write a default config file for Chef (\fB/etc/chef/client\.rb\fR) using values from the \fBknife\.rb\fR\.
.
.IP "\(bu" 4
Create a JSON attributes file containing the specified run list and run Chef\.
.
.IP "" 0
.
.P
In the case of the RubyGems, the \fBclient\.rb\fR will be written from scratch with a minimal set of values; see \fBEXAMPLES\fR\. In the case of APT Package installation, \fBclient\.rb\fR will have the \fBvalidation_client_name\fR appended if it is not set to \fBchef\-validator\fR (default config value), and the \fBnode_name\fR will be added if \fBchef_node_name\fR option is specified\.
.
.P
When this is complete, the bootstrapped node will have:
.
.IP "\(bu" 4
Latest Chef version installed from RubyGems or APT Packages from Opscode\. This may be a later version than the local system\.
.
.IP "\(bu" 4
Be validated with the configured Chef Server\.
.
.IP "\(bu" 4
Have run Chef with its default run list if one is specfied\.
.
.IP "" 0
.
.P
Additional custom bootstrap templates can be created and stored in \fB\.chef/bootstrap/DISTRO\.erb\fR, replacing \fBDISTRO\fR with the value passed with the \fB\-d\fR or \fB\-\-distro\fR option\. See \fBEXAMPLES\fR for more information\.
.
.SH "SEE ALSO"
\fBknife\-ssh\fR(1)
.
.SH "AUTHOR"
Chef was written by Adam Jacob \fIadam@opscode\.com\fR with many contributions from the community\.
.
.SH "DOCUMENTATION"
This manual page was written by Joshua Timberman \fIjoshua@opscode\.com\fR\. Permission is granted to copy, distribute and / or modify this document under the terms of the Apache 2\.0 License\.
.
.SH "CHEF"
Knife is distributed with Chef\. \fIhttp://wiki\.opscode\.com/display/chef/Home\fR