Loading context-linux/src/usr/bin/onegate.rb +3 −0 Original line number Diff line number Diff line Loading @@ -443,6 +443,7 @@ module OneGate def initialize(opts={}) @vmid = ENV["VMID"] @token = ENV["TOKENTXT"] @content_type = opts[:content_type] || 'application/json' url = opts[:url] || ENV['ONEGATE_ENDPOINT'] @uri = URI.parse(url) Loading Loading @@ -476,6 +477,7 @@ module OneGate def post(path, body) req = Net::HTTP::Proxy(@host, @port)::Post.new(path) req.body = body req.content_type = @content_type do_request(req) end Loading @@ -483,6 +485,7 @@ module OneGate def put(path, body) req = Net::HTTP::Proxy(@host, @port)::Put.new(path) req.body = body req.content_type = @content_type do_request(req) end Loading Loading
context-linux/src/usr/bin/onegate.rb +3 −0 Original line number Diff line number Diff line Loading @@ -443,6 +443,7 @@ module OneGate def initialize(opts={}) @vmid = ENV["VMID"] @token = ENV["TOKENTXT"] @content_type = opts[:content_type] || 'application/json' url = opts[:url] || ENV['ONEGATE_ENDPOINT'] @uri = URI.parse(url) Loading Loading @@ -476,6 +477,7 @@ module OneGate def post(path, body) req = Net::HTTP::Proxy(@host, @port)::Post.new(path) req.body = body req.content_type = @content_type do_request(req) end Loading @@ -483,6 +485,7 @@ module OneGate def put(path, body) req = Net::HTTP::Proxy(@host, @port)::Put.new(path) req.body = body req.content_type = @content_type do_request(req) end Loading