Commit c0dcd4de authored by Lucas Nussbaum's avatar Lucas Nussbaum

[dev] set custom user-agent (bug 9602)

parent 37080b5b
Pipeline #56698 passed with stages
in 1 minute and 32 seconds
......@@ -273,7 +273,7 @@ def get_oar_data(site_uid, filename, options)
puts "Downloading resources properties from #{api_uri} ..." if options[:verbose]
http = Net::HTTP.new(api_uri.host, Net::HTTP.https_default_port)
http.use_ssl = true
request = Net::HTTP::Get.new(api_uri.request_uri)
request = Net::HTTP::Get.new(api_uri.request_uri, {'User-Agent' => 'reference-repository/gen/oar-properties'})
# For outside g5k network access
if options[:api][:user] && options[:api][:pwd]
......
......@@ -128,7 +128,7 @@ def get_site_dead_nodes(site_uid, options)
puts "Downloading OAR resources properties from #{api_uri} ..." if options[:verbose]
http = Net::HTTP.new(api_uri.host, Net::HTTP.https_default_port)
http.use_ssl = true
request = Net::HTTP::Get.new(api_uri.request_uri)
request = Net::HTTP::Get.new(api_uri.request_uri, {'User-Agent' => 'reference-repository/valid/homogeneity'})
# For outside g5k network access
if options[:api][:user] && options[:api][:pwd]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment