My fix turned out to be that I had to modify http.rb under /usr/lib/ruby/site_ruby/1.8/puppet/reports/ My new version looks like:
require 'puppet'
require 'net/http'
require 'net/https' <== added
require 'uri'
Puppet::Reports.register_report(:http) do
desc <<-DESC
Send report information via HTTP to the `reporturl`. Each host sends
its report as a YAML dump and this sends this YAML to a client via HTTP POST.
The YAML is the `report` parameter of the request."
DESC
def process
url = URI.parse(Puppet[:reporturl])
req = Net::HTTP::Post.new(url.path)
req.body = self.to_yaml
req.content_type = "application/x-yaml"
# Net::HTTP.new(url.host, url.port).start {|http|
# http.request(req)
# add these lines to replace the above 2
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
req.basic_auth("username", "password")
response = http.start {|http| http.request(req)
}
end
end
There's a more secure way to do this with certificates, I just haven't gotten there yet.