Skip to content

Commit

Permalink
Merge pull request #59 from Anirudh-Gupta/master
Browse files Browse the repository at this point in the history
http_rescue not required with tempfile
  • Loading branch information
smurawski committed Jun 9, 2016
2 parents f54aed2 + 9d06f78 commit 0c69c35
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 1 addition & 3 deletions libraries/profile.rb
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,7 @@ class ComplianceProfile < Chef::Resource # rubocop:disable Metrics/ClassLength
Chef::Config[:ssl_verify_mode] = :verify_none # FIXME

rest = Chef::ServerAPI.new(url, Chef::Config)
tf = with_http_rescue do
rest.binmode_streaming_request(url)
end
rest.binmode_streaming_request(url)
end

case node['platform']
Expand Down
4 changes: 1 addition & 3 deletions libraries/report.rb
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,7 @@ class ComplianceReport < Chef::Resource
Chef::Log.info "Report to: #{url}"

rest = Chef::ServerAPI.new(url, Chef::Config)
with_http_rescue do
rest.post(url, blob)
end
rest.post(url, blob)
end
fail "#{total_failed} audits have failed. Aborting chef-client run." if total_failed > 0 && run_context.node.audit.fail_if_any_audits_failed
end
Expand Down

0 comments on commit 0c69c35

Please sign in to comment.