Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Small change to campfire contact to allow the use of a proxy to get to outside world #120

Open
wants to merge 1 commit into from

1 participant

@crayman

Our production environments cannot use the campfire notifier without going through a proxy. Thank You.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Dec 5, 2012
This page is out of date. Refresh to see the latest.
Showing with 3 additions and 3 deletions.
  1. +3 −3 lib/god/contacts/campfire.rb
View
6 lib/god/contacts/campfire.rb
@@ -32,7 +32,7 @@ def base_url
def find_room_id_by_name(room)
url = URI.parse("#{base_url}/rooms.json")
- http = Net::HTTP.new(url.host, url.port)
+ http = Net::HTTP::Proxy(@options[:proxy_addr],@options[:proxy_port]).new(url.host, url.port)
http.use_ssl = true if @options[:ssl]
req = Net::HTTP::Get.new(url.path)
@@ -55,7 +55,7 @@ def speak(room, message)
url = URI.parse("#{base_url}/room/#{room_id}/speak.json")
- http = Net::HTTP.new(url.host, url.port)
+ http = Net::HTTP::Proxy(@options[:proxy_addr],@options[:proxy_port]).new(url.host, url.port)
http.use_ssl = true if @options[:ssl]
req = Net::HTTP::Post.new(url.path)
@@ -79,7 +79,7 @@ module Contacts
class Campfire < Contact
class << self
- attr_accessor :subdomain, :token, :room, :ssl
+ attr_accessor :subdomain, :token, :room, :ssl, :proxy_host, :proxy_port
attr_accessor :format
end
Something went wrong with that request. Please try again.