chef 12.14.89-universal-mingw32 → 12.15.19-universal-mingw32

Sign up to get free protection for your applications and to get access to all the features.
Files changed (62) hide show
  1. checksums.yaml +4 -4
  2. data/CONTRIBUTING.md +76 -51
  3. data/Gemfile +1 -1
  4. data/README.md +9 -7
  5. data/Rakefile +1 -1
  6. data/VERSION +1 -1
  7. data/acceptance/Gemfile +3 -0
  8. data/acceptance/Gemfile.lock +19 -18
  9. data/acceptance/fips/.kitchen.yml +1 -1
  10. data/lib/chef/application/exit_code.rb +9 -0
  11. data/lib/chef/cookbook/file_system_file_vendor.rb +7 -8
  12. data/lib/chef/cookbook/metadata.rb +8 -0
  13. data/lib/chef/exceptions.rb +5 -0
  14. data/lib/chef/knife.rb +14 -15
  15. data/lib/chef/knife/ssh.rb +1 -0
  16. data/lib/chef/node/attribute.rb +1 -3
  17. data/lib/chef/node/attribute_collections.rb +20 -0
  18. data/lib/chef/provider/apt_repository.rb +1 -1
  19. data/lib/chef/provider/apt_update.rb +1 -1
  20. data/lib/chef/provider/group/groupadd.rb +2 -1
  21. data/lib/chef/provider/package/cab.rb +150 -0
  22. data/lib/chef/provider/package/rubygems.rb +0 -1
  23. data/lib/chef/provider/registry_key.rb +26 -2
  24. data/lib/chef/provider/remote_file/content.rb +1 -1
  25. data/lib/chef/provider/user.rb +10 -0
  26. data/lib/chef/provider/user/dscl.rb +2 -2
  27. data/lib/chef/provider/user/linux.rb +4 -14
  28. data/lib/chef/provider/user/pw.rb +2 -2
  29. data/lib/chef/provider/user/solaris.rb +15 -0
  30. data/lib/chef/provider/user/useradd.rb +1 -5
  31. data/lib/chef/providers.rb +1 -0
  32. data/lib/chef/resource/cab_package.rb +44 -0
  33. data/lib/chef/resource/registry_key.rb +3 -3
  34. data/lib/chef/resource/yum_repository.rb +1 -1
  35. data/lib/chef/resources.rb +1 -0
  36. data/lib/chef/server_api.rb +1 -1
  37. data/lib/chef/util/dsc/local_configuration_manager.rb +1 -1
  38. data/lib/chef/version.rb +1 -1
  39. data/spec/data/templates/chef-seattle20160930-4388-1crv7ef.txt +1 -0
  40. data/spec/data/templates/chef-seattle20160930-4388-jjfoae.txt +1 -0
  41. data/spec/data/templates/chef-seattle20160930-4388-umeq2c.txt +1 -0
  42. data/spec/functional/knife/cookbook_delete_spec.rb +48 -59
  43. data/spec/functional/resource/ifconfig_spec.rb +6 -0
  44. data/spec/functional/resource/registry_spec.rb +110 -4
  45. data/spec/unit/application/exit_code_spec.rb +10 -0
  46. data/spec/unit/cookbook/file_vendor_spec.rb +15 -0
  47. data/spec/unit/cookbook/metadata_spec.rb +19 -0
  48. data/spec/unit/exceptions_spec.rb +2 -0
  49. data/spec/unit/node/attribute_spec.rb +23 -1
  50. data/spec/unit/node/vivid_mash_spec.rb +27 -0
  51. data/spec/unit/provider/group/groupadd_spec.rb +118 -99
  52. data/spec/unit/provider/package/cab_spec.rb +218 -0
  53. data/spec/unit/provider/package/rubygems_spec.rb +2 -4
  54. data/spec/unit/provider/registry_key_spec.rb +94 -0
  55. data/spec/unit/provider/remote_file/content_spec.rb +1 -0
  56. data/spec/unit/provider/user/solaris_spec.rb +52 -40
  57. data/spec/unit/resource/apt_update_spec.rb +25 -17
  58. data/spec/unit/resource/cab_package_spec.rb +38 -0
  59. data/spec/unit/resource/registry_key_spec.rb +26 -10
  60. data/spec/unit/server_api_spec.rb +50 -0
  61. data/spec/unit/util/dsc/local_configuration_manager_spec.rb +10 -4
  62. metadata +13 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3daf0726643cb9b9cd3dca2cb37bc12ff3009c20
4
- data.tar.gz: 4f4353858da7eb9eac52d8621494d2e03190fd5e
3
+ metadata.gz: fdff855af6b1978652b146ddf6dce78339a3de73
4
+ data.tar.gz: 39f168a5e890fbbbe2add9c7cfb62115ae50d9d0
5
5
  SHA512:
6
- metadata.gz: 25b42830580cbfbce4124b77b80d5bf9a6f4c41459047906e45b0a2665de8f2978ac1a5e97c2949c68db6a26cfe40661a656154b1627561c184deafa572772a9
7
- data.tar.gz: 125f0a69175c8407f010a91a1a2862c1df176e1f3243883914ca01951af33522f0da5b13c50806213e8f8a1bb23884b95de648d377f375095b02a001c4d0a314
6
+ metadata.gz: 36b1a99cd2958010f5337ec93704b1561f72f25d30b889b6308ccc9c774332940cff13650dfaeacb189ca815641bbf2b0680a0e8d438b9e9e4eac8a310a2c17c
7
+ data.tar.gz: 54d7f145e3cd4ca6ab034e1c899fa8bb1cafe633f6256e4a3f9b4c4a4f2a93852a16730518b30048e8977b12a1d93a1d080b4f62f5e15a0e8b9382533f4180eb
@@ -1,58 +1,102 @@
1
- # Contributing to Chef
1
+ # Contributing to Chef Projects
2
2
 
3
- We are glad you want to contribute to Chef!
3
+ We're glad you want to contribute to a Chef project! This document will help answer common questions you may have during your first contribution.
4
4
 
5
- We utilize **Github Issues** for issue tracking and contributions. You can contribute in two ways:
5
+ ## Submitting Issues
6
6
 
7
- 1. Reporting an issue or making a feature request [here](#issues).
8
- 2. Adding features or fixing bugs yourself and contributing your code to Chef.
7
+ Not every contribution comes in the form of code. Submitting, confirming, and triaging issues is an important task for any project. At Chef we use Github to track all project issues.
8
+
9
+ If you are familiar with Chef and know the component, that is causing you a problem, you can file an issue in the corresponding Github project. All of our Open Source Software can be found in our [Github organization](https://github.com/chef/). All projects include Github issue templates to help gather information needed for a thorough review.
10
+
11
+ We ask you not to submit security concerns via Github. For details on submitting potential security issues please see <https://www.chef.io/security/>
12
+
13
+ In addition to Github issues, we also utilize a feedback site that helps our product team track and rank feature requests. If you have a feature request, this is an excellent place to start <https://feedback.chef.io>
9
14
 
10
15
  ## Contribution Process
11
16
 
12
- We have a 3 step process that utilizes **Github Issues**:
17
+ We have a 3 step process for contributions:
13
18
 
14
- 1. Sign or be added to an existing [Contributor License Agreement (CLA)](https://supermarket.chef.io/become-a-contributor).
15
- 2. Create a Github Pull Request.
16
- 3. Do [Code Review](#cr) with the **Chef Engineering Team** or **Chef Core Committers** on the pull request.
19
+ 1. Commit changes to a git branch, making sure to sign-off those changes for the [Developer Certificate of Origin](#developer-certification-of-origin-dco).
20
+ 2. Create a Github Pull Request for your change, following the instructions in the pull request template.
21
+ 3. Perform a [Code Review](#code-review-process) with the project maintainers on the pull request.
17
22
 
18
- ### Chef Pull Requests
23
+ ### Pull Request Requirements
19
24
 
20
- Chef is built to last. We strive to ensure high quality throughout the Chef experience. In order to ensure this, we require a couple of things for all pull requests to Chef:
25
+ Chef Projects are built to last. We strive to ensure high quality throughout the experience. In order to ensure this, we require that all pull requests to Chef projects meet these specifications:
21
26
 
22
- 1. **Tests:** To ensure high quality code and protect against future regressions, we require all the code in Chef to have at least unit test coverage. See the [spec/unit](https://github.com/chef/chef/tree/master/spec/unit) directory for the existing tests and use `bundle exec rake spec` to run them.
23
- 2. **Green Travis Run:** We use [Travis CI](https://travis-ci.org/) in order to run our tests continuously on all the pull requests. We require the Travis runs to succeed on every pull request before being merged.
27
+ 1. **Tests:** To ensure high quality code and protect against future regressions, we require all the code in Chef Projects to have at least unit test coverage. We use [RSpec](http://rspec.info/) for unit testing.
28
+ 2. **Green CI Tests:** We use [Travis CI](https://travis-ci.org/) and/or [AppVeyor](https://www.appveyor.com/) CI systems to test all pull requests. We require these test runs to succeed on every pull request before being merged.
24
29
 
25
- ### Chef Code Review Process
30
+ ### Code Review Process
26
31
 
27
- The Chef Code Review process happens on Github pull requests. See [this article](https://help.github.com/articles/using-pull-requests) if you're not familiar with Github Pull Requests.
32
+ Code review takes place in Github pull requests. See [this article](https://help.github.com/articles/about-pull-requests/) if you're not familiar with Github Pull Requests.
28
33
 
29
- Once you open a pull request, the **Chef Engineering Team** or **Chef Core Committers** will review your code and respond to you with any feedback they might have. The process at this point is as follows:
34
+ Once you open a pull request, project maintainers will review your code and respond to your pull request with any feedback they might have. The process at this point is as follows:
30
35
 
31
- 1. 2 thumbs-ups are required from the **Chef Engineering Team** or **Chef Core Committers** for all merges.
36
+ 1. Two thumbs-up (:+1:) are required from project maintainers. See the master maintainers document for Chef projects at <https://github.com/chef/chef/blob/master/MAINTAINERS.md>.
32
37
  2. When ready, your pull request will be tagged with label `Ready For Merge`.
33
- 3. Your patch will be merged into `master` including necessary documentation updates and you will be included in `CHANGELOG.md`. Our goal is to have patches merged in 2 weeks after they are marked to be merged.
38
+ 3. Your change will be merged into the project's `master` branch and will be noted in the project's `CHANGELOG.md` at the time of release.
34
39
 
35
- If you would like to learn about when your code will be available in a release of Chef, read more about [Chef Release Cycles](#chef-release-cycles).
40
+ If you would like to learn about when your code will be available in a release of Chef, read more about [Chef Release Cycles](#release-cycles).
36
41
 
37
- ### Contributor License Agreement (CLA)
42
+ ### Developer Certification of Origin (DCO)
38
43
 
39
44
  Licensing is very important to open source projects. It helps ensure the software continues to be available under the terms that the author desired.
40
45
 
41
46
  Chef uses [the Apache 2.0 license](https://github.com/chef/chef/blob/master/LICENSE) to strike a balance between open contribution and allowing you to use the software however you would like to.
42
47
 
43
- The license tells you what rights you have that are provided by the copyright holder. It is important that the contributor fully understands what rights they are licensing and agrees to them. Sometimes the copyright holder isn't the contributor, such as when the contributor is doing work for a company.
48
+ The license tells you what rights you have that are provided by the copyright holder. It is important that the contributor fully understands what rights they are licensing and agrees to them. Sometimes the copyright holder isn't the contributor, such as when the contributor is doing work on behalf of a company.
49
+
50
+ To make a good faith effort to ensure these criteria are met, Chef requires the Developer Certificate of Origin (DCO) process to be followed.
51
+
52
+ The DCO is an attestation attached to every contribution made by every developer. In the commit message of the contribution, the developer simply adds a Signed-off-by statement and thereby agrees to the DCO, which you can find below or at <http://developercertificate.org/>.
53
+
54
+ ```
55
+ Developer's Certificate of Origin 1.1
56
+
57
+ By making a contribution to this project, I certify that:
58
+
59
+ (a) The contribution was created in whole or in part by me and I
60
+ have the right to submit it under the open source license
61
+ indicated in the file; or
62
+
63
+ (b) The contribution is based upon previous work that, to the
64
+ best of my knowledge, is covered under an appropriate open
65
+ source license and I have the right under that license to
66
+ submit that work with modifications, whether created in whole
67
+ or in part by me, under the same open source license (unless
68
+ I am permitted to submit under a different license), as
69
+ Indicated in the file; or
70
+
71
+ (c) The contribution was provided directly to me by some other
72
+ person who certified (a), (b) or (c) and I have not modified
73
+ it.
74
+
75
+ (d) I understand and agree that this project and the contribution
76
+ are public and that a record of the contribution (including
77
+ all personal information I submit with it, including my
78
+ sign-off) is maintained indefinitely and may be redistributed
79
+ consistent with this project or the open source license(s)
80
+ involved.
81
+ ```
82
+
83
+ For more information on the change see the Chef Blog post [Introducing Developer Certificate of Origin](https://blog.chef.io/2016/09/19/introducing-developer-certificate-of-origin/)
84
+
85
+ #### DCO Sign-Off Methods
44
86
 
45
- To make a good faith effort to ensure these criteria are met, Chef requires an Individual CLA or a Corporate CLA for contributions. This agreement helps ensure you are aware of the terms of the license you are contributing your copyrighted works under, which helps to prevent the inclusion of works in the projects that the contributor does not hold the rights to share.
87
+ The DCO requires a sign-off message in the following format appear on each commit in the pull request:
46
88
 
47
- It only takes a few minutes to complete a CLA, and you retain the copyright to your contribution.
89
+ ```
90
+ Signed-off-by: Julia Child <juliachild@chef.io>
91
+ ```
48
92
 
49
- You can complete our [Individual CLA](https://supermarket.chef.io/icla-signatures/new) online. If you're contributing on behalf of your employer and they retain the copyright for your works, have your employer fill out our [Corporate CLA](https://supermarket.chef.io/ccla-signatures/new) instead.
93
+ The DCO text can either be manually added to your commit body, or you can add either **-s** or **--signoff** to your usual git commit commands. If you forget to add the sign-off you can also amend a previous commit with the sign-off by running **git commit –-amend -s**. If you've pushed your changes to Github already you'll need to force push your branch after this with **git push -f**.
50
94
 
51
95
  ### Chef Obvious Fix Policy
52
96
 
53
- Small contributions such as fixing spelling errors, where the content is small enough to not be considered intellectual property, can be submitted by a contributor as a patch, without a CLA.
97
+ Small contributions, such as fixing spelling errors, where the content is small enough to not be considered intellectual property, can be submitted without signing the contribution for the DCO.
54
98
 
55
- As a rule of thumb, changes are obvious fixes if they do not introduce any new functionality or creative thinking. As long as the change does not affect functionality, some likely examples include the following:
99
+ As a rule of thumb, changes are obvious fixes if they do not introduce any new functionality or creative thinking. Assuming the change does not affect functionality, some common obvious fix examples include the following:
56
100
 
57
101
  - Spelling / grammar fixes
58
102
  - Typo correction, white space and formatting changes
@@ -67,36 +111,17 @@ As a rule of thumb, changes are obvious fixes if they do not introduce any new f
67
111
  ```
68
112
  ------------------------------------------------------------------------
69
113
  commit 370adb3f82d55d912b0cf9c1d1e99b132a8ed3b5
70
- Author: danielsdeleo <dan@chef.io>
71
- Date: Wed Sep 18 11:44:40 2013 -0700
114
+ Author: Julia Child <juliachild@chef.io>
115
+ Date: Wed Sep 18 11:44:40 2015 -0700
72
116
 
73
- Fix typo in config file docs.
117
+ Fix typo in the README.
74
118
 
75
119
  Obvious fix.
76
120
 
77
121
  ------------------------------------------------------------------------
78
122
  ```
79
123
 
80
- ## Chef Issue Tracking
81
-
82
- Chef Issue Tracking is handled using Github Issues.
83
-
84
- If you are familiar with Chef and know the component that is causing you a problem or if you have a feature request on a specific component you can file an issue in the corresponding Github project. All of our Open Source Software can be found in our [Github organization](https://github.com/chef/).
85
-
86
- There is also a listing of the various Chef products and where to file issues that can be found in the Chef docs in the [community contributions section](https://docs.chef.io/community_contributions.html#issues-and-bug-reports).
87
-
88
- Otherwise you can file your issue in the [Chef project](https://github.com/chef/chef/issues) and we will make sure it gets filed against the appropriate project.
89
-
90
- ### Useful Github Queries
91
-
92
- Contributions go through a review process to improve code quality and avoid regressions. Managing a large number of contributions requires a workflow to provide queues for work such as triage, code review, and merging. A semi-formal process has evolved over the life of the project. Chef maintains this process pending community development and acceptance of an [RFC](https://github.com/chef/chef-rfc). These queries will help track contributions through this process:
93
-
94
- - [Issues that are not assigned to a team](https://github.com/chef/chef/issues?q=is%3Aopen+-label%3AAIX+-label%3ABSD+-label%3Awindows+-label%3A%22Chef+Core%22++-label%3A%22Dev+Tools%22+-label%3AUbuntu+-label%3A%22Enterprise+Linux%22+-label%3A%22Ready+For+Merge%22+-label%3AMac+-label%3ASolaris+)
95
- - [Untriaged Issues](https://github.com/chef/chef/issues?q=is%3Aopen+is%3Aissue+-label%3ABug+-label%3AEnhancement+-label%3A%22Tech+Cleanup%22+-label%3A%22Ready+For+Merge%22)
96
- - [PRs to be Reviewed](https://github.com/chef/chef/labels/Pending%20Maintainer%20Review)
97
- - [Suitable for First Contribution](https://github.com/chef/chef/labels/Easy)
98
-
99
- ## Chef Release Cycles
124
+ ## Release Cycles
100
125
 
101
126
  Our primary shipping vehicle is operating system specific packages that includes all the requirements of Chef. We call these [Omnibus packages](https://github.com/chef/omnibus)
102
127
 
@@ -108,7 +133,7 @@ Our version numbering roughly follows [Semantic Versioning](http://semver.org/)
108
133
  - Y is a minor release, which adds both new features and bug fixes
109
134
  - Z is a patch release, which adds just bug fixes
110
135
 
111
- After shipping a release of Chef we bump the `Minor` version by one to start development of the next minor releaae. All merges to master trigger an increment of the `Patch` version, and a build through our internal testing pipeline. We do a `Minor` release approximately every month, which consist of shipping one of the already auto-incremented and tested `Patch` versions. For example after shiping 12.10.24, we incremented Chef to 12.11.0\. From there 18 commits where merged bringing the version to 12.11.18, which we shipped as an omnibus package.
136
+ After shipping a release of Chef we bump the `Minor` version by one to start development of the next minor release. All merges to master trigger an increment of the `Patch` version, and a build through our internal testing pipeline. We do a `Minor` release approximately every month, which consist of shipping one of the already auto-incremented and tested `Patch` versions. For example after shiping 12.10.24, we incremented Chef to 12.11.0\. From there 18 commits where merged bringing the version to 12.11.18, which we shipped as an omnibus package.
112
137
 
113
138
  Announcements of releases are made to the [chef mailing list](https://discourse.chef.io/c/chef-release) when they are available.
114
139
 
@@ -123,4 +148,4 @@ Also here are some additional pointers to some awesome Chef content:
123
148
 
124
149
  - [Chef Docs](https://docs.chef.io/)
125
150
  - [Learn Chef](https://learn.chef.io/)
126
- - [Chef Inc.](https://www.chef.io/)
151
+ - [Chef Website](https://www.chef.io/)
data/Gemfile CHANGED
@@ -38,7 +38,7 @@ group(:integration) do
38
38
  gem "chefspec"
39
39
  gem "halite"
40
40
  gem "poise"
41
- gem "poise-boiler", git: "https://github.com/poise/poise-boiler"
41
+ gem "poise-boiler"
42
42
  gem "knife-windows"
43
43
  gem "foodcritic"
44
44
 
data/README.md CHANGED
@@ -5,8 +5,8 @@
5
5
 
6
6
  Want to try Chef? Get started with [learnchef](https://learn.chef.io)
7
7
 
8
- * Documentation: [http://docs.chef.io](http://docs.chef.io)
9
- * Source: [http://github.com/chef/chef/tree/master](http://github.com/chef/chef/tree/master)
8
+ * Documentation: [https://docs.chef.io](https://docs.chef.io)
9
+ * Source: [https://github.com/chef/chef/tree/master](https://github.com/chef/chef/tree/master)
10
10
  * Tickets/Issues: [https://github.com/chef/chef/issues](https://github.com/chef/chef/issues)
11
11
  * Slack: [Chef Community Slack](https://community-slack.chef.io/)
12
12
  * Mailing list: [https://discourse.chef.io](https://discourse.chef.io)
@@ -18,14 +18,14 @@ This README focuses on developers who want to modify Chef source code.
18
18
  If you just want to use Chef, check out these resources:
19
19
 
20
20
  * [learnchef](https://learn.chef.io): Getting started guide
21
- * [docs.chef.io](http://docs.chef.io): Comprehensive User Docs
22
- * [Installer Downloads](https://www.chef.io/download-chef-client/): Install Chef as a complete package
21
+ * [docs.chef.io](https://docs.chef.io): Comprehensive User Docs
22
+ * [Installer Downloads](https://downloads.chef.io/chef-client/): Install Chef as a complete package
23
23
 
24
24
  ## Installing From Git
25
25
 
26
26
  **NOTE:** Unless you have a specific reason to install from source (to
27
27
  try a new feature, contribute a patch, or run chef on an OS for which no
28
- package is available), you should head to the [installer page](https://www.chef.io/download-chef-client/)
28
+ package is available), you should head to the [downloads page](https://downloads.chef.io/chef-client/)
29
29
  to get a prebuilt package.
30
30
 
31
31
  ### Prerequisites
@@ -36,7 +36,7 @@ Install these via your platform's preferred method (`apt`, `yum`, `ports`,
36
36
  * git
37
37
  * C compiler, header files, etc. On Ubuntu/Debian, use the
38
38
  `build-essential` package.
39
- * ruby 2.1.0 or later
39
+ * ruby 2.3.0 or later
40
40
  * rubygems
41
41
  * bundler gem
42
42
 
@@ -65,7 +65,7 @@ gem install pkg/chef-VERSION.gem
65
65
 
66
66
  Before working on the code, if you plan to contribute your changes, you need to
67
67
  read the
68
- [Chef Contributions document](http://docs.chef.io/community_contributions.html).
68
+ [Chef Contributions document](https://docs.chef.io/community_contributions.html).
69
69
 
70
70
  The general development process is:
71
71
 
@@ -279,6 +279,7 @@ Chef - A configuration management system
279
279
  | **Copyright:** | Copyright 2008-2016, Chef Software, Inc.
280
280
  | **License:** | Apache License, Version 2.0
281
281
 
282
+ ```
282
283
  Licensed under the Apache License, Version 2.0 (the "License");
283
284
  you may not use this file except in compliance with the License.
284
285
  You may obtain a copy of the License at
@@ -290,3 +291,4 @@ distributed under the License is distributed on an "AS IS" BASIS,
290
291
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
291
292
  See the License for the specific language governing permissions and
292
293
  limitations under the License.
294
+ ```
data/Rakefile CHANGED
@@ -33,7 +33,7 @@ ChefConfig::PackageTask.new(File.expand_path("..", __FILE__), "Chef", "chef") do
33
33
  package.component_paths = ["chef-config"]
34
34
  package.generate_version_class = true
35
35
  end
36
- # Add a conservative dependency update to version:bump (which was created by PackageTask)
36
+ # Add conservative dependency update to version:bump (which was created by PackageTask)
37
37
  task "version:bump" => %w{version:bump_patch version:update}
38
38
  task "version:bump" => %w{version:bump_patch version:update}
39
39
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 12.14.89
1
+ 12.15.19
@@ -11,3 +11,6 @@ gem "kitchen-inspec"
11
11
  gem "test-kitchen"
12
12
  gem "winrm-elevated"
13
13
  gem "berkshelf", "4.3.5"
14
+
15
+ # until 2.0.0 is fixed for unstable packages
16
+ gem "mixlib-install", "1.2.3"
@@ -11,12 +11,12 @@ GEM
11
11
  specs:
12
12
  addressable (2.4.0)
13
13
  artifactory (2.5.0)
14
- aws-sdk (2.6.2)
15
- aws-sdk-resources (= 2.6.2)
16
- aws-sdk-core (2.6.2)
14
+ aws-sdk (2.6.5)
15
+ aws-sdk-resources (= 2.6.5)
16
+ aws-sdk-core (2.6.5)
17
17
  jmespath (~> 1.0)
18
- aws-sdk-resources (2.6.2)
19
- aws-sdk-core (= 2.6.2)
18
+ aws-sdk-resources (2.6.5)
19
+ aws-sdk-core (= 2.6.5)
20
20
  berkshelf (4.3.5)
21
21
  addressable (~> 2.3, >= 2.3.4)
22
22
  berkshelf-api-client (~> 2.0, >= 2.0.2)
@@ -53,7 +53,7 @@ GEM
53
53
  celluloid-io (0.16.2)
54
54
  celluloid (>= 0.16.0)
55
55
  nio4r (>= 1.1.0)
56
- chef-config (12.14.77)
56
+ chef-config (12.14.89)
57
57
  addressable
58
58
  fuzzyurl
59
59
  mixlib-config (~> 2.0)
@@ -61,11 +61,11 @@ GEM
61
61
  cleanroom (1.0.0)
62
62
  coderay (1.1.1)
63
63
  diff-lcs (1.2.5)
64
- docker-api (1.31.0)
64
+ docker-api (1.32.0)
65
65
  excon (>= 0.38.0)
66
66
  json
67
67
  erubis (2.7.0)
68
- excon (0.52.0)
68
+ excon (0.53.0)
69
69
  faraday (0.9.2)
70
70
  multipart-post (>= 1.2, < 3)
71
71
  ffi (1.9.14)
@@ -77,7 +77,7 @@ GEM
77
77
  hashie (3.4.6)
78
78
  hitimes (1.2.4)
79
79
  httpclient (2.7.2)
80
- inspec (0.35.0)
80
+ inspec (1.0.0)
81
81
  hashie (~> 3.4)
82
82
  json (>= 1.8, < 3.0)
83
83
  method_source (~> 0.8)
@@ -90,7 +90,7 @@ GEM
90
90
  rubyzip (~> 1.1)
91
91
  sslshake (~> 1)
92
92
  thor (~> 0.19)
93
- train (>= 0.19.0, < 1.0)
93
+ train (>= 0.19.1, < 1.0)
94
94
  jmespath (1.3.1)
95
95
  json (2.0.2)
96
96
  kitchen-ec2 (1.2.0)
@@ -99,8 +99,8 @@ GEM
99
99
  multi_json
100
100
  retryable (~> 2.0)
101
101
  test-kitchen (~> 1.4, >= 1.4.1)
102
- kitchen-inspec (0.15.1)
103
- inspec (>= 0.22.0, < 1.0.0)
102
+ kitchen-inspec (0.15.2)
103
+ inspec (>= 0.22.0, < 2.0.0)
104
104
  test-kitchen (~> 1.6)
105
105
  kitchen-vagrant (0.20.0)
106
106
  test-kitchen (~> 1.4)
@@ -115,7 +115,7 @@ GEM
115
115
  mixlib-authentication (1.4.1)
116
116
  mixlib-log
117
117
  mixlib-config (2.2.4)
118
- mixlib-install (1.2.2)
118
+ mixlib-install (1.2.3)
119
119
  artifactory
120
120
  mixlib-shellout
121
121
  mixlib-versioning
@@ -163,7 +163,7 @@ GEM
163
163
  rspec-core (~> 3.5.0)
164
164
  rspec-expectations (~> 3.5.0)
165
165
  rspec-mocks (~> 3.5.0)
166
- rspec-core (3.5.3)
166
+ rspec-core (3.5.4)
167
167
  rspec-support (~> 3.5.0)
168
168
  rspec-expectations (3.5.0)
169
169
  diff-lcs (>= 1.2.0, < 2.0)
@@ -187,8 +187,8 @@ GEM
187
187
  molinillo (~> 0.4.2)
188
188
  semverse (~> 1.1)
189
189
  sslshake (1.0.12)
190
- test-kitchen (1.13.0)
191
- mixlib-install (~> 1.2)
190
+ test-kitchen (1.13.2)
191
+ mixlib-install (>= 1.2, < 3.0)
192
192
  mixlib-shellout (>= 1.2, < 3.0)
193
193
  net-scp (~> 1.1)
194
194
  net-ssh (>= 2.9, < 4.0)
@@ -211,7 +211,7 @@ GEM
211
211
  hashie (>= 2.0.2, < 4.0.0)
212
212
  windows_chef_zero (2.0.0)
213
213
  test-kitchen (>= 1.2.1)
214
- winrm (2.0.2)
214
+ winrm (2.0.3)
215
215
  builder (>= 2.1.2)
216
216
  erubis (~> 2.7)
217
217
  gssapi (~> 1.2)
@@ -220,7 +220,7 @@ GEM
220
220
  logging (>= 1.6.1, < 3.0)
221
221
  nori (~> 2.0)
222
222
  rubyntlm (~> 0.6.0, >= 0.6.1)
223
- winrm-elevated (1.0.0)
223
+ winrm-elevated (1.0.1)
224
224
  winrm (~> 2.0)
225
225
  winrm-fs (~> 1.0)
226
226
  winrm-fs (1.0.0)
@@ -239,6 +239,7 @@ DEPENDENCIES
239
239
  kitchen-ec2
240
240
  kitchen-inspec
241
241
  kitchen-vagrant
242
+ mixlib-install (= 1.2.3)
242
243
  test-kitchen
243
244
  windows_chef_zero
244
245
  winrm-elevated
@@ -1,6 +1,6 @@
1
1
  suites:
2
2
  - name: fips-unit-functional
3
- includes: [centos-6, windows-2012r2]
3
+ includes: [centos-6]
4
4
  run_list:
5
5
 
6
6
  - name: fips-integration
@@ -35,6 +35,7 @@ class Chef
35
35
  REBOOT_NEEDED: 37,
36
36
  REBOOT_FAILED: 41,
37
37
  AUDIT_MODE_FAILURE: 42,
38
+ CLIENT_UPGRADED: 213,
38
39
  }
39
40
 
40
41
  DEPRECATED_RFC_062_EXIT_CODES = {
@@ -127,6 +128,8 @@ class Chef
127
128
  VALID_RFC_062_EXIT_CODES[:REBOOT_FAILED]
128
129
  elsif audit_failure?(exception)
129
130
  VALID_RFC_062_EXIT_CODES[:AUDIT_MODE_FAILURE]
131
+ elsif client_upgraded?(exception)
132
+ VALID_RFC_062_EXIT_CODES[:CLIENT_UPGRADED]
130
133
  else
131
134
  VALID_RFC_062_EXIT_CODES[:GENERIC_FAILURE]
132
135
  end
@@ -162,6 +165,12 @@ class Chef
162
165
  end
163
166
  end
164
167
 
168
+ def client_upgraded?(exception)
169
+ resolve_exception_array(exception).any? do |e|
170
+ e.is_a? Chef::Exceptions::ClientUpgraded
171
+ end
172
+ end
173
+
165
174
  def sigint_received?(exception)
166
175
  resolve_exception_array(exception).any? do |e|
167
176
  e.is_a? Chef::Exceptions::SigInt
@@ -37,20 +37,19 @@ class Chef
37
37
  def initialize(manifest, *repo_paths)
38
38
  @cookbook_name = manifest[:cookbook_name]
39
39
  @repo_paths = repo_paths.flatten
40
- raise ArgumentError, "You must specify at least one repo path" if @repo_paths.empty?
40
+ raise ArgumentError, "You must specify at least one repo path" if repo_paths.empty?
41
+ end
42
+
43
+ def cookbooks
44
+ @cookbooks ||= Chef::CookbookLoader.new(repo_paths).load_cookbooks
41
45
  end
42
46
 
43
47
  # Implements abstract base's requirement. It looks in the
44
48
  # Chef::Config.cookbook_path file hierarchy for the requested
45
49
  # file.
46
50
  def get_filename(filename)
47
- location = @repo_paths.inject(nil) do |memo, basepath|
48
- candidate_location = File.join(basepath, @cookbook_name, filename)
49
- memo = candidate_location if File.exist?(candidate_location)
50
- memo
51
- end
52
- raise "File #{filename} does not exist for cookbook #{@cookbook_name}" unless location
53
-
51
+ location = File.join(cookbooks[cookbook_name].root_dir, filename) if cookbooks.has_key?(cookbook_name)
52
+ raise "File #{filename} does not exist for cookbook #{cookbook_name}" unless location && File.exist?(location)
54
53
  location
55
54
  end
56
55