zabbixapi 0.1.8 → 0.1.9
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/zabbixapi/base.rb +3 -3
- data/zabbixapi.gemspec +1 -1
- metadata +1 -1
data/lib/zabbixapi/base.rb
CHANGED
@@ -32,8 +32,8 @@ module Zabbix
|
|
32
32
|
|
33
33
|
@debug = false # Disable debug by default
|
34
34
|
@basic_auth = false #Disable basic_auth by default
|
35
|
-
|
36
|
-
|
35
|
+
|
36
|
+
unless ENV['http_proxy'].nil?
|
37
37
|
@proxy_uri = URI.parse(ENV['http_proxy'])
|
38
38
|
@proxy_host = proxy_uri.host
|
39
39
|
@proxy_port = proxy_uri.port
|
@@ -55,7 +55,7 @@ module Zabbix
|
|
55
55
|
if @proxy_uri.nil?
|
56
56
|
http = Net::HTTP.new(uri.host, uri.port)
|
57
57
|
else
|
58
|
-
http = Net::HTTP.
|
58
|
+
http = Net::HTTP.Proxy(@proxy_host, @proxy_port, @proxy_user, @proxy_pass).new(uri.host, uri.port)
|
59
59
|
end
|
60
60
|
|
61
61
|
if uri.scheme == "https"
|
data/zabbixapi.gemspec
CHANGED