This repository has been archived by the owner on Jul 14, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 170
Upload Cookbooks Specified in Lockfile #119
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -19,10 +19,11 @@ source 'https://rubygems.org' | |||
|
|||
gemspec :name => "chef-dk" | |||
|
|||
gem "chef", ">= 11.14.0.rc.2" | |||
gem "chef", github: "opscode/chef", branch: "policyfile-fixes" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will be removed when we merge the upstream PR.
👍 Nice @danielsdeleo |
name = run_list_item.name | ||
name = "#{name}::default" unless name.include?("::") | ||
"recipe[#{name}]" | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i'll probably try to move this into core-chef to fix node['recipes'] in chef-12.
👍 |
ksubrama
pushed a commit
that referenced
this pull request
Jan 11, 2016
Patch libyaml on windows manually with version 0.1.5.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds library classes and updates required to upload cookbooks from a policyfile lock. This enables full end-to-end use of Policyfile-based config deployment, including policyfile compilation, cookbook install from upstreams, publish to Chef Server, and chef-client run. As with previous Policyfile features, the upload feature isn't exposed in the CLI yet, so you have to write a small script to drive the library code. An example of this can be found here: https://github.com/danielsdeleo/policyfile-jenkins-demo
There are some open issues I plan to address in future pull requests:
Policyfile.lock.json
needs to be more defensive, since users will probably modify them by hand even though that's a terrible idea.Policyfile.lock.json
was computed. In some cases (particularly local development), we expect this to happen as part of an "edit, run chef or tests, repeat" development cycle, so that use case needs to work well.This pull request depends on some changes in chef-client which can be reviewed here: chef/chef#1716 That pull request includes some incompatible changes to internal-ish APIs, so I think we should play it safe and merge only for 12.0. This implies that we're moving ChefDK's internal chef-client dep to 12.0, which should be fine, but we cannot load tools like
chefspec
into the same ruby VM instance until those tools update./cc @opscode/client-engineers