-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for Berkshelf #2
Conversation
This adds preferential support for Berkshelf instead of Librarian for uploading a chef-repo to a chef-zero server. If a Berksfile is present, it will be used, otherwise Librarian is used to upload dependent cookbooks. Note that 'berks upload' is not used, as that may upload to the real chef server, though this is a future optimization to consider.
I think #1 should solve this problem without adding specific Berkshelf support |
@@ -7,3 +7,5 @@ | |||
require 'chefdepartie/cookbook' | |||
require 'chefdepartie/databag' | |||
require 'chefdepartie/cache' | |||
|
|||
Chefdepartie.run(background: true, config: 'config.rb', cache: nil) |
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.
was this done for testing? I don't think we want this hardcoded here
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.
Yes it was done for testing. Also was following the README, which doesn't work without this line... i.e. bundle exec ruby lib/chefdepartie.rb
simply returns without it.
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.
good to merge once this is removed, I'll update the readme
You're correct about that, I think that this change still probably has merit though, as most people either use librarian or berkshelf |
If the tests were running in travis (which I should make them do), I think they would probably fail with this change, as they assert that it outputs 'uploading librarian cookboks'. |
Fixed tests with 8d1890c |
This adds preferential support for Berkshelf instead of Librarian for
uploading a chef-repo to a chef-zero server. If a Berksfile is present,
it will be used, otherwise Librarian is used to upload dependent
cookbooks. Note that 'berks upload' is not used, as that may upload to
the real chef server, though this is a future optimization to consider.