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
server enforced required recipe #6032
Conversation
lib/chef/data_collector.rb
Outdated
@@ -384,6 +384,8 @@ def data_collector_token | |||
end | |||
|
|||
def add_resource_report(resource_report) | |||
#require 'pry' |
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.
let's get these removed please
when the chef-server is configured to serve a requried recipe, chef-client shall load the recipe into the run context and execute it as part of the converge phase. if the chef-server is NOT configured, it will return a 404 and chef-client will continue normally. Signed-off-by: Stephen Delano <stephen@chef.io>
0dbeba4
to
adb0a55
Compare
Signed-off-by: Stephen Delano <stephen@chef.io>
Signed-off-by: Stephen Delano <stephen@chef.io>
# to create your own rest client, perhaps we should do that | ||
# here but it seems more appropriate to reuse one that we | ||
# know is already created. for ease of testing, we'll pass | ||
# the existing rest client in as a parameter |
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.
you should probably use rest_clean
here, so that JSON request/response is sanitized
we probably should have converted everything over to rest_clean
for Chef-13
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.
The comments around #rest_clean
indicate that it's used for API reporters. If it is indeed related to JSON sanitization, that's also non-applicable here because neither the request nor the response contain any JSON. This is simply a GET
to retrieve a recipe file.
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 guess the point is that rest
is kinda-sorta deprecated and rest_clean
is the future -- at some point rest
should just set the same options as rest_clean
and then rest_clean
should go away.
it might not make any difference at all, but that's kind of fine and useful to know...
server enforced required recipe Signed-off-by: Daniel DeLeo <dan@chef.io>
Backport #6032 (required recipe) to Chef 12
when the chef-server is configured to serve a requried recipe,
chef-client shall load the recipe into the run context and
execute it as part of the converge phase.
if the chef-server is NOT configured, it will return a 404 and
chef-client will continue normally.
Signed-off-by: Stephen Delano stephen@chef.io
Description
See above.
See also:
Issues Resolved
Check List