chef 10.20.0 → 10.22.0.rc.0
Sign up to get free protection for your applications and to get access to all the features.
- data/distro/common/html/chef-client.8.html +3 -3
- data/distro/common/html/chef-expander.8.html +3 -3
- data/distro/common/html/chef-expanderctl.8.html +3 -3
- data/distro/common/html/chef-server-webui.8.html +3 -3
- data/distro/common/html/chef-server.8.html +3 -3
- data/distro/common/html/chef-solo.8.html +3 -3
- data/distro/common/html/chef-solr.8.html +3 -3
- data/distro/common/html/knife-bootstrap.1.html +4 -4
- data/distro/common/html/knife-client.1.html +4 -4
- data/distro/common/html/knife-configure.1.html +3 -3
- data/distro/common/html/knife-cookbook-site.1.html +6 -6
- data/distro/common/html/knife-cookbook.1.html +3 -3
- data/distro/common/html/knife-data-bag.1.html +3 -3
- data/distro/common/html/knife-environment.1.html +6 -6
- data/distro/common/html/knife-exec.1.html +3 -3
- data/distro/common/html/knife-index.1.html +4 -4
- data/distro/common/html/knife-node.1.html +3 -3
- data/distro/common/html/knife-role.1.html +3 -3
- data/distro/common/html/knife-search.1.html +3 -3
- data/distro/common/html/knife-ssh.1.html +3 -3
- data/distro/common/html/knife-status.1.html +3 -3
- data/distro/common/html/knife-tag.1.html +3 -3
- data/distro/common/html/knife.1.html +11 -11
- data/distro/common/html/shef.1.html +3 -3
- data/distro/common/man/man1/knife-bootstrap.1 +1 -1
- data/distro/common/man/man1/knife-client.1 +1 -1
- data/distro/common/man/man1/knife-configure.1 +1 -1
- data/distro/common/man/man1/knife-cookbook-site.1 +1 -1
- data/distro/common/man/man1/knife-cookbook.1 +1 -1
- data/distro/common/man/man1/knife-data-bag.1 +1 -1
- data/distro/common/man/man1/knife-environment.1 +1 -1
- data/distro/common/man/man1/knife-exec.1 +1 -1
- data/distro/common/man/man1/knife-index.1 +1 -1
- data/distro/common/man/man1/knife-node.1 +1 -1
- data/distro/common/man/man1/knife-role.1 +1 -1
- data/distro/common/man/man1/knife-search.1 +1 -1
- data/distro/common/man/man1/knife-ssh.1 +1 -1
- data/distro/common/man/man1/knife-status.1 +1 -1
- data/distro/common/man/man1/knife-tag.1 +1 -1
- data/distro/common/man/man1/knife.1 +1 -1
- data/distro/common/man/man1/shef.1 +1 -1
- data/distro/common/man/man8/chef-client.8 +1 -1
- data/distro/common/man/man8/chef-expander.8 +1 -1
- data/distro/common/man/man8/chef-expanderctl.8 +1 -1
- data/distro/common/man/man8/chef-server-webui.8 +1 -1
- data/distro/common/man/man8/chef-server.8 +1 -1
- data/distro/common/man/man8/chef-solo.8 +1 -1
- data/distro/common/man/man8/chef-solr.8 +1 -1
- data/lib/chef/cookbook_version.rb +1 -1
- data/lib/chef/json_compat.rb +94 -1
- data/lib/chef/provider/cookbook_file.rb +24 -0
- data/lib/chef/resource.rb +18 -0
- data/lib/chef/version.rb +1 -1
- data/lib/chef/win32/api/process.rb +1 -0
- data/lib/chef/win32/handle.rb +8 -1
- data/spec/data/big_json.json +2 -1
- data/spec/data/big_json_plus_one.json +2 -1
- data/spec/functional/resource/cookbook_file_spec.rb +18 -0
- data/spec/support/shared/functional/file_resource.rb +21 -0
- data/spec/support/shared/functional/securable_resource.rb +74 -70
- data/spec/unit/json_compat_spec.rb +61 -0
- metadata +23 -33
- data/spec/unit/json_compat_spect.rb +0 -53
@@ -133,11 +133,11 @@ option.</dd>
|
|
133
133
|
|
134
134
|
<h2 id="AUTHOR">AUTHOR</h2>
|
135
135
|
|
136
|
-
<p> Chef was written by Adam Jacob <a data-bare-link="true" href="&#
|
136
|
+
<p> Chef was written by Adam Jacob <a data-bare-link="true" href="mailto:adam@opscode.com">adam@opscode.com</a> with many contributions from the community.</p>
|
137
137
|
|
138
138
|
<h2 id="DOCUMENTATION">DOCUMENTATION</h2>
|
139
139
|
|
140
|
-
<p> This manual page was written by Joshua Timberman <a data-bare-link="true" href="m&#
|
140
|
+
<p> This manual page was written by Joshua Timberman <a data-bare-link="true" href="mailto:joshua@opscode.com">joshua@opscode.com</a>.
|
141
141
|
Permission is granted to copy, distribute and / or modify this document under the terms of the Apache 2.0 License.</p>
|
142
142
|
|
143
143
|
<h2 id="CHEF">CHEF</h2>
|
@@ -146,7 +146,7 @@ option.</dd>
|
|
146
146
|
|
147
147
|
|
148
148
|
<ol class='man-decor man-foot man foot'>
|
149
|
-
<li class='tl'>Chef 10.
|
149
|
+
<li class='tl'>Chef 10.22.0.rc.0</li>
|
150
150
|
<li class='tc'>February 2013</li>
|
151
151
|
<li class='tr'>knife-ssh(1)</li>
|
152
152
|
</ol>
|
@@ -105,11 +105,11 @@ may not be publicly reachable.</p>
|
|
105
105
|
|
106
106
|
<h2 id="AUTHOR">AUTHOR</h2>
|
107
107
|
|
108
|
-
<p> Chef was written by Adam Jacob <a href="ma&#
|
108
|
+
<p> Chef was written by Adam Jacob <a href="mailto:adam@opscode.com" data-bare-link="true">adam@opscode.com</a> with many contributions from the community.</p>
|
109
109
|
|
110
110
|
<h2 id="DOCUMENTATION">DOCUMENTATION</h2>
|
111
111
|
|
112
|
-
<p> This manual page was written by Joshua Timberman <a href="m&#
|
112
|
+
<p> This manual page was written by Joshua Timberman <a href="mailto:joshua@opscode.com" data-bare-link="true">joshua@opscode.com</a>.
|
113
113
|
Permission is granted to copy, distribute and / or modify this document under the terms of the Apache 2.0 License.</p>
|
114
114
|
|
115
115
|
<h2 id="CHEF">CHEF</h2>
|
@@ -118,7 +118,7 @@ may not be publicly reachable.</p>
|
|
118
118
|
|
119
119
|
|
120
120
|
<ol class='man-decor man-foot man foot'>
|
121
|
-
<li class='tl'>Chef 10.
|
121
|
+
<li class='tl'>Chef 10.22.0.rc.0</li>
|
122
122
|
<li class='tc'>February 2013</li>
|
123
123
|
<li class='tr'>knife-status(1)</li>
|
124
124
|
</ol>
|
@@ -114,11 +114,11 @@
|
|
114
114
|
|
115
115
|
<h2 id="AUTHOR">AUTHOR</h2>
|
116
116
|
|
117
|
-
<p> Chef was written by Adam Jacob <a data-bare-link="true" href="&#
|
117
|
+
<p> Chef was written by Adam Jacob <a data-bare-link="true" href="mailto:adam@opscode.com">adam@opscode.com</a> with many contributions from the community.</p>
|
118
118
|
|
119
119
|
<h2 id="DOCUMENTATION">DOCUMENTATION</h2>
|
120
120
|
|
121
|
-
<p> This manual page was written by Daniel DeLeo <a data-bare-link="true" href="m&#
|
121
|
+
<p> This manual page was written by Daniel DeLeo <a data-bare-link="true" href="mailto:dan@opscode.com">dan@opscode.com</a>.
|
122
122
|
Permission is granted to copy, distribute and / or modify this document under the terms of the Apache 2.0 License.</p>
|
123
123
|
|
124
124
|
<h2 id="CHEF">CHEF</h2>
|
@@ -127,7 +127,7 @@
|
|
127
127
|
|
128
128
|
|
129
129
|
<ol class='man-decor man-foot man foot'>
|
130
|
-
<li class='tl'>Chef 10.
|
130
|
+
<li class='tl'>Chef 10.22.0.rc.0</li>
|
131
131
|
<li class='tc'>February 2013</li>
|
132
132
|
<li class='tr'>knife-tag(1)</li>
|
133
133
|
</ol>
|
@@ -279,38 +279,38 @@ data editing entirely.</dd>
|
|
279
279
|
<strong><span class="man-ref">knife-node<span class="s">(1)</span></span></strong> <strong><span class="man-ref">knife-recipe<span class="s">(1)</span></span></strong> <strong><span class="man-ref">knife-role<span class="s">(1)</span></span></strong>
|
280
280
|
<strong><span class="man-ref">knife-search<span class="s">(1)</span></span></strong> <strong><span class="man-ref">knife-ssh<span class="s">(1)</span></span></strong> <strong><span class="man-ref">knife-tag<span class="s">(1)</span></span></strong></p>
|
281
281
|
|
282
|
-
<p> Complete Chef documentation is available online: <a
|
282
|
+
<p> Complete Chef documentation is available online: <a href="http://wiki.opscode.com/display/chef/Home/" data-bare-link="true">http://wiki.opscode.com/display/chef/Home/</a></p>
|
283
283
|
|
284
|
-
<p> JSON is JavaScript Object Notation <a
|
284
|
+
<p> JSON is JavaScript Object Notation <a href="http://json.org/" data-bare-link="true">http://json.org/</a></p>
|
285
285
|
|
286
|
-
<p> SOLR is an open source search engine. <a
|
286
|
+
<p> SOLR is an open source search engine. <a href="http://lucene.apache.org/solr/" data-bare-link="true">http://lucene.apache.org/solr/</a></p>
|
287
287
|
|
288
|
-
<p> <strong><span class="man-ref">git<span class="s">(1)</span></span></strong> is a version control system <a
|
288
|
+
<p> <strong><span class="man-ref">git<span class="s">(1)</span></span></strong> is a version control system <a href="http://git-scm.com/" data-bare-link="true">http://git-scm.com/</a></p>
|
289
289
|
|
290
|
-
<p> This manual page was generated from Markdown with <strong><span class="man-ref">ronn<span class="s">(1)</span></span></strong> <a
|
290
|
+
<p> This manual page was generated from Markdown with <strong><span class="man-ref">ronn<span class="s">(1)</span></span></strong> <a href="http://rtomayko.github.com/ronn/ronn.1.html" data-bare-link="true">http://rtomayko.github.com/ronn/ronn.1.html</a></p>
|
291
291
|
|
292
292
|
<h2 id="AUTHOR">AUTHOR</h2>
|
293
293
|
|
294
|
-
<p> Chef was written by Adam Jacob <a
|
295
|
-
(<a
|
294
|
+
<p> Chef was written by Adam Jacob <a href="mailto:adam@opscode.com" data-bare-link="true">adam@opscode.com</a> of Opscode
|
295
|
+
(<a href="http://www.opscode.com" data-bare-link="true">http://www.opscode.com</a>), with contributions from the community.</p>
|
296
296
|
|
297
297
|
<h2 id="DOCUMENTATION">DOCUMENTATION</h2>
|
298
298
|
|
299
|
-
<p> This manual page was written by Joshua Timberman <a
|
299
|
+
<p> This manual page was written by Joshua Timberman <a href="mailto:joshua@opscode.com" data-bare-link="true">joshua@opscode.com</a>.</p>
|
300
300
|
|
301
301
|
<h2 id="LICENSE">LICENSE</h2>
|
302
302
|
|
303
303
|
<p> Both Chef and this documentation are released under the terms of the
|
304
|
-
Apache 2.0 License. You may view the license online: <a
|
304
|
+
Apache 2.0 License. You may view the license online: <a href="http://www.apache.org/licenses/LICENSE-2.0.html" data-bare-link="true">http://www.apache.org/licenses/LICENSE-2.0.html</a>
|
305
305
|
On some systems, the complete text of the Apache 2.0 License may be found in <code>/usr/share/common-licenses/Apache-2.0</code>.</p>
|
306
306
|
|
307
307
|
<h2 id="CHEF">CHEF</h2>
|
308
308
|
|
309
|
-
<p> Knife is distributed with Chef. <a
|
309
|
+
<p> Knife is distributed with Chef. <a href="http://wiki.opscode.com/display/chef/Home" data-bare-link="true">http://wiki.opscode.com/display/chef/Home</a></p>
|
310
310
|
|
311
311
|
|
312
312
|
<ol class='man-decor man-foot man foot'>
|
313
|
-
<li class='tl'>Chef 10.
|
313
|
+
<li class='tl'>Chef 10.22.0.rc.0</li>
|
314
314
|
<li class='tc'>February 2013</li>
|
315
315
|
<li class='tr'>knife(1)</li>
|
316
316
|
</ol>
|
@@ -258,12 +258,12 @@ and may become out of sync with the behavior of those libraries.</p>
|
|
258
258
|
|
259
259
|
<h2 id="AUTHOR">AUTHOR</h2>
|
260
260
|
|
261
|
-
<p> Chef was written by Adam Jacob <a data-bare-link="true" href="mailt&#
|
261
|
+
<p> Chef was written by Adam Jacob <a data-bare-link="true" href="mailto:adam@opscode.com">adam@opscode.com</a> with many
|
262
262
|
contributions from the community. Shef was written by Daniel DeLeo.</p>
|
263
263
|
|
264
264
|
<h2 id="DOCUMENTATION">DOCUMENTATION</h2>
|
265
265
|
|
266
|
-
<p> This manual page was written by Daniel DeLeo <a data-bare-link="true" href="m&#
|
266
|
+
<p> This manual page was written by Daniel DeLeo <a data-bare-link="true" href="mailto:dan@opscode.com">dan@opscode.com</a>.
|
267
267
|
Permission is granted to copy, distribute and / or modify this
|
268
268
|
document under the terms of the Apache 2.0 License.</p>
|
269
269
|
|
@@ -273,7 +273,7 @@ and may become out of sync with the behavior of those libraries.</p>
|
|
273
273
|
|
274
274
|
|
275
275
|
<ol class='man-decor man-foot man foot'>
|
276
|
-
<li class='tl'>Chef 10.
|
276
|
+
<li class='tl'>Chef 10.22.0.rc.0</li>
|
277
277
|
<li class='tc'>February 2013</li>
|
278
278
|
<li class='tr'>shef(1)</li>
|
279
279
|
</ol>
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-BOOTSTRAP" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-BOOTSTRAP" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-bootstrap\fR \- Install Chef Client on a remote host
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-CLIENT" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-CLIENT" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-client\fR \- Manage Chef API Clients
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-CONFIGURE" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-CONFIGURE" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-configure\fR \- Generate configuration files for knife or Chef Client
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-COOKBOOK\-SITE" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-COOKBOOK\-SITE" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-cookbook\-site\fR \- Install and update open source cookbooks
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-COOKBOOK" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-COOKBOOK" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-cookbook\fR \- upload and manage chef cookbooks
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-DATA\-BAG" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-DATA\-BAG" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-data\-bag\fR \- Store arbitrary data on a Chef Server
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-ENVIRONMENT" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-ENVIRONMENT" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-environment\fR \- Define cookbook policies for the environments in your infrastructure
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-EXEC" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-EXEC" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-exec\fR \- Run user scripts using the Chef API DSL
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-INDEX" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-INDEX" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-index\fR \- Rebuild the search index on a Chef Server
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-NODE" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-NODE" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-node\fR \- Manage the hosts in your infrastructure
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-ROLE" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-ROLE" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-role\fR \- Group common configuration settings
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-SEARCH" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-SEARCH" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-search\fR \- Find objects on a Chef Server by query
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-SSH" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-SSH" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-ssh\fR \- Run a command or interactive session on multiple remote hosts
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-STATUS" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-STATUS" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-status\fR \- Display status information for the nodes in your infrastructure
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE\-TAG" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE\-TAG" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\-tag\fR \- Apply tags to nodes on a Chef Server
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "KNIFE" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "KNIFE" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBknife\fR \- Chef Server API client utility
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "SHEF" "1" "February 2013" "Chef 10.
|
4
|
+
.TH "SHEF" "1" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBshef\fR \- Interactive Chef Console
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "CHEF\-CLIENT" "8" "February 2013" "Chef 10.
|
4
|
+
.TH "CHEF\-CLIENT" "8" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBchef\-client\fR \- Runs a client node connecting to a chef\-server\.
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "CHEF\-EXPANDER" "8" "February 2013" "Chef 10.
|
4
|
+
.TH "CHEF\-EXPANDER" "8" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBchef\-expander\fR \- fetches messages from RabbitMQ, processes, and loads into chef\-solr
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "CHEF\-EXPANDERCTL" "8" "February 2013" "Chef 10.
|
4
|
+
.TH "CHEF\-EXPANDERCTL" "8" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBchef\-expanderctl\fR \- management program for chef\-expander
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "CHEF\-SERVER\-WEBUI" "8" "February 2013" "Chef 10.
|
4
|
+
.TH "CHEF\-SERVER\-WEBUI" "8" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBchef\-server\-webui\fR \- Start the Chef Server merb application slice providing Web User Interface (Management Console)\.
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "CHEF\-SERVER" "8" "February 2013" "Chef 10.
|
4
|
+
.TH "CHEF\-SERVER" "8" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBchef\-server\fR \- Start the Chef Server merb application slice\.
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "CHEF\-SOLO" "8" "February 2013" "Chef 10.
|
4
|
+
.TH "CHEF\-SOLO" "8" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBchef\-solo\fR \- Runs chef in solo mode against a specified cookbook location\.
|
@@ -1,7 +1,7 @@
|
|
1
1
|
.\" generated with Ronn/v0.7.3
|
2
2
|
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
3
|
.
|
4
|
-
.TH "CHEF\-SOLR" "8" "February 2013" "Chef 10.
|
4
|
+
.TH "CHEF\-SOLR" "8" "February 2013" "Chef 10.22.0.rc.0" "Chef Manual"
|
5
5
|
.
|
6
6
|
.SH "NAME"
|
7
7
|
\fBchef\-solr\fR \- Runs as Chef\'s search server
|
@@ -787,7 +787,7 @@ class Chef
|
|
787
787
|
cookbook_version.manifest = o
|
788
788
|
|
789
789
|
# We don't need the following step when we decide to stop supporting deprecated operators in the metadata (e.g. <<, >>)
|
790
|
-
cookbook_version.manifest["metadata"] =
|
790
|
+
cookbook_version.manifest["metadata"] = Chef::JSONCompat.from_json(cookbook_version.metadata.to_json)
|
791
791
|
|
792
792
|
cookbook_version.freeze_version if o["frozen?"]
|
793
793
|
cookbook_version
|
data/lib/chef/json_compat.rb
CHANGED
@@ -24,6 +24,21 @@ class Chef
|
|
24
24
|
class JSONCompat
|
25
25
|
JSON_MAX_NESTING = 1000
|
26
26
|
|
27
|
+
JSON_CLASS = "json_class".freeze
|
28
|
+
|
29
|
+
CHEF_APICLIENT = "Chef::ApiClient".freeze
|
30
|
+
CHEF_COOKBOOKVERSION = "Chef::CookbookVersion".freeze
|
31
|
+
CHEF_DATABAG = "Chef::DataBag".freeze
|
32
|
+
CHEF_DATABAGITEM = "Chef::DataBagItem".freeze
|
33
|
+
CHEF_ENVIRONMENT = "Chef::Environment".freeze
|
34
|
+
CHEF_NODE = "Chef::Node".freeze
|
35
|
+
CHEF_ROLE = "Chef::Role".freeze
|
36
|
+
CHEF_SANDBOX = "Chef::Sandbox".freeze
|
37
|
+
CHEF_RESOURCE = "Chef::Resource".freeze
|
38
|
+
CHEF_RESOURCECOLLECTION = "Chef::ResourceCollection".freeze
|
39
|
+
CHEF_WEBUIUSER = "Chef::WebUIUser".freeze
|
40
|
+
CHEF_OPENIDREGISTRAION = "Chef::OpenIDRegistration".freeze
|
41
|
+
|
27
42
|
class <<self
|
28
43
|
# See CHEF-1292/PL-538. Increase the max nesting for JSON, which defaults
|
29
44
|
# to 19, and isn't enough for some (for example, a Node within a Node)
|
@@ -38,7 +53,49 @@ class Chef
|
|
38
53
|
|
39
54
|
# Just call the JSON gem's parse method with a modified :max_nesting field
|
40
55
|
def from_json(source, opts = {})
|
41
|
-
::
|
56
|
+
obj = ::Yajl::Parser.parse(source)
|
57
|
+
|
58
|
+
unless obj.kind_of?(Hash) || obj.kind_of?(Array)
|
59
|
+
raise JSON::ParserError, "Top level JSON object must be a Hash or Array (actual: #{obj.class})"
|
60
|
+
end
|
61
|
+
|
62
|
+
# The old default in the json gem (which we are mimicing because we
|
63
|
+
# sadly rely on this misfeature) is to "create additions" i.e., convert
|
64
|
+
# JSON objects into ruby objects. Explicit :create_additions => false
|
65
|
+
# is required to turn it off.
|
66
|
+
if opts[:create_additions].nil? || opts[:create_additions]
|
67
|
+
map_to_rb_obj(obj)
|
68
|
+
else
|
69
|
+
obj
|
70
|
+
end
|
71
|
+
rescue Yajl::ParseError => e
|
72
|
+
raise JSON::ParserError, e.message
|
73
|
+
end
|
74
|
+
|
75
|
+
# Look at an object that's a basic type (from json parse) and convert it
|
76
|
+
# to an instance of Chef classes if desired.
|
77
|
+
def map_to_rb_obj(json_obj)
|
78
|
+
res = case json_obj
|
79
|
+
when Hash
|
80
|
+
mapped_hash = map_hash_to_rb_obj(json_obj)
|
81
|
+
if json_obj.has_key?(JSON_CLASS) && (class_to_inflate = class_for_json_class(json_obj[JSON_CLASS]))
|
82
|
+
class_to_inflate.json_create(mapped_hash)
|
83
|
+
else
|
84
|
+
mapped_hash
|
85
|
+
end
|
86
|
+
when Array
|
87
|
+
json_obj.map {|e| map_to_rb_obj(e) }
|
88
|
+
else
|
89
|
+
json_obj
|
90
|
+
end
|
91
|
+
res
|
92
|
+
end
|
93
|
+
|
94
|
+
def map_hash_to_rb_obj(json_hash)
|
95
|
+
json_hash.each do |key, value|
|
96
|
+
json_hash[key] = map_to_rb_obj(value)
|
97
|
+
end
|
98
|
+
json_hash
|
42
99
|
end
|
43
100
|
|
44
101
|
def to_json(obj, opts = nil)
|
@@ -48,6 +105,42 @@ class Chef
|
|
48
105
|
def to_json_pretty(obj, opts = nil)
|
49
106
|
::JSON.pretty_generate(obj, opts_add_max_nesting(opts))
|
50
107
|
end
|
108
|
+
|
109
|
+
|
110
|
+
def class_for_json_class(json_class)
|
111
|
+
case json_class
|
112
|
+
when CHEF_APICLIENT
|
113
|
+
Chef::ApiClient
|
114
|
+
when CHEF_COOKBOOKVERSION
|
115
|
+
Chef::CookbookVersion
|
116
|
+
when CHEF_DATABAG
|
117
|
+
Chef::DataBag
|
118
|
+
when CHEF_DATABAGITEM
|
119
|
+
Chef::DataBagItem
|
120
|
+
when CHEF_ENVIRONMENT
|
121
|
+
Chef::Environment
|
122
|
+
when CHEF_NODE
|
123
|
+
Chef::Node
|
124
|
+
when CHEF_ROLE
|
125
|
+
Chef::Role
|
126
|
+
when CHEF_SANDBOX
|
127
|
+
Chef::Sandbox
|
128
|
+
when CHEF_RESOURCE
|
129
|
+
Chef::Resource
|
130
|
+
when CHEF_RESOURCECOLLECTION
|
131
|
+
Chef::ResourceCollection
|
132
|
+
when CHEF_WEBUIUSER
|
133
|
+
Chef::WebUIUser
|
134
|
+
when CHEF_OPENIDREGISTRAION
|
135
|
+
Chef::OpenIDRegistration
|
136
|
+
when /^Chef::Resource/
|
137
|
+
Chef::Resource.find_subclass_by_name(json_class)
|
138
|
+
else
|
139
|
+
raise JSON::ParserError, "Unsupported `json_class` type '#{json_class}'"
|
140
|
+
end
|
141
|
+
end
|
142
|
+
|
51
143
|
end
|
52
144
|
end
|
53
145
|
end
|
146
|
+
|