X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/3a4d52bd4c0f8e6ae7679145846b7bc7845d8ace..20907a228bd7d16981bbc1657f8c994e6837838e:/cookbooks/trac/files/default/trac-authenticate?ds=inline diff --git a/cookbooks/trac/files/default/trac-authenticate b/cookbooks/trac/files/default/trac-authenticate index 489a12ca0..a25563736 100755 --- a/cookbooks/trac/files/default/trac-authenticate +++ b/cookbooks/trac/files/default/trac-authenticate @@ -9,7 +9,9 @@ pass = gets.chop request = Net::HTTP::Get.new("/api/0.6/user/details") request.basic_auth user, pass -response = Net::HTTP.new("api.openstreetmap.org").request(request) +response = Net::HTTP.start("api.openstreetmap.org", :use_ssl => true) do |http| + http.request(request) +end exit!(0) if response.is_a?(Net::HTTPSuccess) exit!(1)