Skip to content

Commit

Permalink
Add initializer and bin approval listener
Browse files Browse the repository at this point in the history
  • Loading branch information
syncrou committed Mar 25, 2019
1 parent 2cb1cc9 commit 0415e1e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
11 changes: 11 additions & 0 deletions bin/approval_request_listener
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/usr/bin/env ruby

$LOAD_PATH << File.expand_path("../lib", __dir__)
require "bundler/setup"
require "approval_request_listener"

queue_host = ENV["QUEUE_HOST"] || "localhost"
queue_port = ENV["QUEUE_PORT"] || 9092

approval_request_listener = ApprovalRequestListener.new(:host => queue_host, :port => queue_port)
approval_request_listener.run
7 changes: 7 additions & 0 deletions config/initializers/approval_request_listener.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Be sure to restart your server when you modify this file.

queue_host = ENV["QUEUE_HOST"] || "localhost"
queue_port = ENV["QUEUE_PORT"] || 9092

approval_request_listener = ApprovalRequestListener.new(:host => queue_host, :port => queue_port)
approval_request_listener.run

0 comments on commit 0415e1e

Please sign in to comment.