consul_bridge 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +9 -0
- data/Dockerfile +28 -0
- data/Gemfile +7 -0
- data/README.md +36 -0
- data/Rakefile +2 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/consul_bridge.gemspec +30 -0
- data/docker-entrypoint.sh +8 -0
- data/exe/consul_bridge +5 -0
- data/lib/consul_bridge/base.rb +13 -0
- data/lib/consul_bridge/bootstrap_consul.rb +28 -0
- data/lib/consul_bridge/bootstrap_consul_actor.rb +25 -0
- data/lib/consul_bridge/cli.rb +24 -0
- data/lib/consul_bridge/detect_consul.rb +27 -0
- data/lib/consul_bridge/detect_consul_bootstrap.rb +7 -0
- data/lib/consul_bridge/download_masters.rb +29 -0
- data/lib/consul_bridge/get_private_ip.rb +15 -0
- data/lib/consul_bridge/join_consul.rb +50 -0
- data/lib/consul_bridge/monitor_docker_events.rb +26 -0
- data/lib/consul_bridge/monitor_docker_events_actor.rb +25 -0
- data/lib/consul_bridge/run_bridge.rb +65 -0
- data/lib/consul_bridge/version.rb +3 -0
- data/lib/consul_bridge.rb +5 -0
- metadata +194 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: dfd60f5dd66669d4d6969825051528ff14dd1656
|
4
|
+
data.tar.gz: 248189761023dfdd74584e2288e2adae7634a54a
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: a7113cc0fac29e51400e23bf846baf8a1a505055427142630879d475132bd3b9df46c70b9058c7a73e93a3525d0fda1997fe50cd433736a06d52e24d2525beed
|
7
|
+
data.tar.gz: 49b4979952902083516157256d25cce03c08460fe6160199036ac82dbc4b0700eb95b80048de91b0b5616e267ee1d6e4140a03410abdc8b54ff37ca4218ead66
|
data/.gitignore
ADDED
data/Dockerfile
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
FROM outstand/ruby-base:2.2.4-alpine
|
2
|
+
MAINTAINER Ryan Schlesinger <ryan@outstand.com>
|
3
|
+
|
4
|
+
RUN addgroup bridge && \
|
5
|
+
adduser -S -G bridge bridge
|
6
|
+
|
7
|
+
ENV CONSUL_BRIDGE_VERSION=0.1.0
|
8
|
+
|
9
|
+
# Use this to install an official release
|
10
|
+
RUN apk --no-cache add libxml2 libxslt \
|
11
|
+
&& apk --no-cache add --virtual build-dependencies build-base libxml2-dev libxslt-dev \
|
12
|
+
&& gem install nokogiri -- --use-system-libraries \
|
13
|
+
&& gem install consul_bridge -v ${CONSUL_BRIDGE_VERSION} \
|
14
|
+
&& apk del build-dependencies
|
15
|
+
|
16
|
+
# Use this to install a development version
|
17
|
+
# RUN apk --no-cache add build-base libxml2-dev libxslt-dev
|
18
|
+
# COPY . /consul_bridge/
|
19
|
+
# RUN cd /consul_bridge \
|
20
|
+
# && bundle config build.nokogiri --use-system-libraries \
|
21
|
+
# && bundle install \
|
22
|
+
# && bundle exec rake install
|
23
|
+
|
24
|
+
COPY docker-entrypoint.sh /docker-entrypoint.sh
|
25
|
+
|
26
|
+
ENV DUMB_INIT_SETSID 0
|
27
|
+
ENTRYPOINT ["/docker-entrypoint.sh"]
|
28
|
+
CMD []
|
data/Gemfile
ADDED
data/README.md
ADDED
@@ -0,0 +1,36 @@
|
|
1
|
+
# ConsulBridge
|
2
|
+
|
3
|
+
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/consul_bridge`. To experiment with that code, run `bin/console` for an interactive prompt.
|
4
|
+
|
5
|
+
TODO: Delete this and the text above, and describe your gem
|
6
|
+
|
7
|
+
## Installation
|
8
|
+
|
9
|
+
Add this line to your application's Gemfile:
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
gem 'consul_bridge'
|
13
|
+
```
|
14
|
+
|
15
|
+
And then execute:
|
16
|
+
|
17
|
+
$ bundle
|
18
|
+
|
19
|
+
Or install it yourself as:
|
20
|
+
|
21
|
+
$ gem install consul_bridge
|
22
|
+
|
23
|
+
## Usage
|
24
|
+
|
25
|
+
TODO: Write usage instructions here
|
26
|
+
|
27
|
+
## Development
|
28
|
+
|
29
|
+
After checking out the repo, run `bin/setup` to install dependencies. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
30
|
+
|
31
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
32
|
+
|
33
|
+
## Contributing
|
34
|
+
|
35
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/consul_bridge.
|
36
|
+
|
data/Rakefile
ADDED
data/bin/console
ADDED
@@ -0,0 +1,14 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
require "bundler/setup"
|
4
|
+
require "consul_bridge"
|
5
|
+
|
6
|
+
# You can add fixtures and/or initialization code here to make experimenting
|
7
|
+
# with your gem easier. You can also use a different console, if you like.
|
8
|
+
|
9
|
+
# (If you use this, don't forget to add pry to your Gemfile!)
|
10
|
+
# require "pry"
|
11
|
+
# Pry.start
|
12
|
+
|
13
|
+
require "irb"
|
14
|
+
IRB.start
|
data/bin/setup
ADDED
@@ -0,0 +1,30 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'consul_bridge/version'
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "consul_bridge"
|
8
|
+
spec.version = ConsulBridge::VERSION
|
9
|
+
spec.authors = ["Ryan Schlesinger"]
|
10
|
+
spec.email = ["ryan@outstand.com"]
|
11
|
+
|
12
|
+
spec.summary = %q{Discover consul master nodes and join local agent}
|
13
|
+
spec.homepage = 'https://github.com/outstand/consul_bridge'
|
14
|
+
|
15
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
16
|
+
spec.bindir = "exe"
|
17
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
18
|
+
spec.require_paths = ["lib"]
|
19
|
+
|
20
|
+
spec.add_runtime_dependency 'thor', '~> 0.19'
|
21
|
+
spec.add_runtime_dependency 'excon', '~> 0.49.0'
|
22
|
+
spec.add_runtime_dependency 'fog-aws', '~> 0.9'
|
23
|
+
spec.add_runtime_dependency 'mime-types', '~> 3.0'
|
24
|
+
spec.add_runtime_dependency 'docker-api', '~> 1.28'
|
25
|
+
spec.add_runtime_dependency 'concurrent-ruby', '~> 1.0'
|
26
|
+
spec.add_runtime_dependency 'concurrent-ruby-edge', '~> 0.2'
|
27
|
+
|
28
|
+
spec.add_development_dependency "bundler", "~> 1.11"
|
29
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
30
|
+
end
|
data/exe/consul_bridge
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
require 'consul_bridge/base'
|
2
|
+
require 'consul_bridge/detect_consul'
|
3
|
+
require 'consul_bridge/detect_consul_bootstrap'
|
4
|
+
require 'consul_bridge/download_masters'
|
5
|
+
require 'consul_bridge/join_consul'
|
6
|
+
|
7
|
+
module ConsulBridge
|
8
|
+
class BootstrapConsul < Base
|
9
|
+
attr_accessor :bucket, :join_all
|
10
|
+
|
11
|
+
def initialize(bucket:, join_all: false)
|
12
|
+
self.bucket = bucket
|
13
|
+
self.join_all = join_all
|
14
|
+
end
|
15
|
+
|
16
|
+
def call
|
17
|
+
while !DetectConsul.call.running
|
18
|
+
puts 'Local consul agent not detected, sleeping for 5 seconds'
|
19
|
+
sleep 5
|
20
|
+
end
|
21
|
+
|
22
|
+
puts '==> Bootstrapping consul'
|
23
|
+
master_ips = DownloadMasters.call(bucket: self.bucket).master_ips
|
24
|
+
JoinConsul.call(master_ips: master_ips, join_all: self.join_all)
|
25
|
+
puts '==> Done.'
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
@@ -0,0 +1,25 @@
|
|
1
|
+
require 'concurrent'
|
2
|
+
require 'concurrent-edge'
|
3
|
+
require 'consul_bridge/bootstrap_consul'
|
4
|
+
|
5
|
+
module ConsulBridge
|
6
|
+
class BootstrapConsulActor < Concurrent::Actor::RestartingContext
|
7
|
+
def initialize(bucket:, join_all: false)
|
8
|
+
@bucket = bucket
|
9
|
+
@join_all = join_all
|
10
|
+
end
|
11
|
+
|
12
|
+
def on_message(message)
|
13
|
+
if message == :bootstrap
|
14
|
+
begin
|
15
|
+
BootstrapConsul.call(bucket: @bucket, join_all: @join_all)
|
16
|
+
rescue => e
|
17
|
+
puts "Warning: #{e.message}; retrying in 5 seconds"
|
18
|
+
Concurrent::ScheduledTask.execute(5){ tell :bootstrap }
|
19
|
+
end
|
20
|
+
else
|
21
|
+
pass
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
@@ -0,0 +1,24 @@
|
|
1
|
+
require 'thor'
|
2
|
+
|
3
|
+
module ConsulBridge
|
4
|
+
class CLI < Thor
|
5
|
+
desc 'version', 'Print out the version string'
|
6
|
+
def version
|
7
|
+
say ConsulBridge::VERSION.to_s
|
8
|
+
end
|
9
|
+
|
10
|
+
desc 'start', 'Start the bridge'
|
11
|
+
option :bucket, aliases: '-b', required: true, type: :string, banner: '<s3_bucket>'
|
12
|
+
option :container_name, aliases: '-n', required: true, type: :string, banner: '<container_name>'
|
13
|
+
option :join_all, aliases: '-a', type: :boolean, default: false
|
14
|
+
def start
|
15
|
+
$stdout.sync = true
|
16
|
+
require 'consul_bridge/run_bridge'
|
17
|
+
RunBridge.call(
|
18
|
+
bucket: options[:bucket],
|
19
|
+
container_name: options[:container_name],
|
20
|
+
join_all: options[:join_all]
|
21
|
+
)
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
@@ -0,0 +1,27 @@
|
|
1
|
+
require 'consul_bridge/base'
|
2
|
+
require 'excon'
|
3
|
+
|
4
|
+
module ConsulBridge
|
5
|
+
class DetectConsul < Base
|
6
|
+
URL = 'http://127.0.0.1:8500/v1/agent/self'.freeze
|
7
|
+
|
8
|
+
def call
|
9
|
+
running = true
|
10
|
+
begin
|
11
|
+
Excon.get(
|
12
|
+
URL,
|
13
|
+
expects: [200],
|
14
|
+
connect_timeout: 5,
|
15
|
+
read_timeout: 5,
|
16
|
+
write_timeout: 5,
|
17
|
+
tcp_nodelay: true
|
18
|
+
)
|
19
|
+
rescue Excon::Errors::SocketError, Excon::Errors::HTTPStatusError
|
20
|
+
running = false
|
21
|
+
end
|
22
|
+
OpenStruct.new(
|
23
|
+
running: running
|
24
|
+
)
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
@@ -0,0 +1,29 @@
|
|
1
|
+
require 'consul_bridge/base'
|
2
|
+
require 'fog/aws'
|
3
|
+
|
4
|
+
module ConsulBridge
|
5
|
+
class DownloadMasters < Base
|
6
|
+
attr_accessor :bucket
|
7
|
+
|
8
|
+
def initialize(bucket:)
|
9
|
+
self.bucket = bucket
|
10
|
+
end
|
11
|
+
|
12
|
+
def call
|
13
|
+
puts "Downloading master ips from bucket #{self.bucket}"
|
14
|
+
|
15
|
+
master_ips = []
|
16
|
+
|
17
|
+
storage = Fog::Storage.new provider: 'AWS', use_iam_profile: true
|
18
|
+
bucket = storage.directories.get(self.bucket)
|
19
|
+
bucket.files.each do |file|
|
20
|
+
master_ips << file.key
|
21
|
+
end
|
22
|
+
|
23
|
+
OpenStruct.new(
|
24
|
+
master_ips: master_ips
|
25
|
+
)
|
26
|
+
end
|
27
|
+
|
28
|
+
end
|
29
|
+
end
|
@@ -0,0 +1,15 @@
|
|
1
|
+
require 'consul_bridge/base'
|
2
|
+
require 'excon'
|
3
|
+
|
4
|
+
module ConsulBridge
|
5
|
+
class GetPrivateIP < Base
|
6
|
+
URL = 'http://169.254.169.254/latest/meta-data/local-ipv4'.freeze
|
7
|
+
|
8
|
+
def call
|
9
|
+
response = Excon.get(URL, expects: [200], connect_timeout: 10, read_timeout: 10, write_timeout: 10, tcp_nodelay: true)
|
10
|
+
OpenStruct.new(
|
11
|
+
private_ip: response.body
|
12
|
+
)
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -0,0 +1,50 @@
|
|
1
|
+
require 'consul_bridge/base'
|
2
|
+
require 'consul_bridge/get_private_ip'
|
3
|
+
require 'excon'
|
4
|
+
|
5
|
+
module ConsulBridge
|
6
|
+
class JoinConsul < Base
|
7
|
+
attr_accessor :master_ips, :join_all
|
8
|
+
|
9
|
+
JOIN_URL = 'http://127.0.0.1:8500/v1/agent/join'.freeze
|
10
|
+
|
11
|
+
def initialize(master_ips:, join_all: false)
|
12
|
+
self.master_ips = master_ips
|
13
|
+
self.join_all = join_all
|
14
|
+
end
|
15
|
+
|
16
|
+
def call
|
17
|
+
private_ip = GetPrivateIP.call.private_ip
|
18
|
+
puts "Detected private ip: #{private_ip}"
|
19
|
+
puts "Starting join with [#{master_ips.join(', ')}]"
|
20
|
+
|
21
|
+
joined = 0
|
22
|
+
master_ips.each do |ip|
|
23
|
+
next if ip == private_ip
|
24
|
+
begin
|
25
|
+
puts "Trying to join #{ip}"
|
26
|
+
Excon.get(
|
27
|
+
JOIN_URL + "/#{ip}",
|
28
|
+
expects: [200],
|
29
|
+
connect_timeout: 5,
|
30
|
+
read_timeout: 11,
|
31
|
+
write_timeout: 5,
|
32
|
+
tcp_nodelay: true
|
33
|
+
)
|
34
|
+
puts "Joined #{ip}"
|
35
|
+
joined += 1
|
36
|
+
break unless self.join_all
|
37
|
+
rescue Excon::Errors::HTTPStatusError, Excon::Errors::SocketError
|
38
|
+
next
|
39
|
+
end
|
40
|
+
end
|
41
|
+
|
42
|
+
if join_all && joined < 2
|
43
|
+
raise 'Unable to join at least 2 masters with join_all'
|
44
|
+
elsif !join_all && joined < 1
|
45
|
+
raise 'Unable to join any master'
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
49
|
+
end
|
50
|
+
end
|
@@ -0,0 +1,26 @@
|
|
1
|
+
require 'consul_bridge/base'
|
2
|
+
require 'docker-api'
|
3
|
+
|
4
|
+
module ConsulBridge
|
5
|
+
class MonitorDockerEvents < Base
|
6
|
+
attr_accessor :container_name, :handler
|
7
|
+
|
8
|
+
def initialize(container_name:, handler:)
|
9
|
+
self.container_name = container_name
|
10
|
+
self.handler = handler
|
11
|
+
end
|
12
|
+
|
13
|
+
def call
|
14
|
+
begin
|
15
|
+
filters = {type: [:container], event: [:start], container: [self.container_name]}.to_json
|
16
|
+
Docker::Event.stream(filters: filters) do |event|
|
17
|
+
self.handler.call(event)
|
18
|
+
end
|
19
|
+
rescue Docker::Error::TimeoutError
|
20
|
+
retry
|
21
|
+
rescue Excon::Errors::SocketError
|
22
|
+
retry
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
@@ -0,0 +1,25 @@
|
|
1
|
+
require 'concurrent'
|
2
|
+
require 'concurrent-edge'
|
3
|
+
require 'consul_bridge/monitor_docker_events'
|
4
|
+
|
5
|
+
module ConsulBridge
|
6
|
+
class MonitorDockerEventsActor < Concurrent::Actor::RestartingContext
|
7
|
+
def initialize(bootstrap_actor:, container_name:)
|
8
|
+
@bootstrap_actor = bootstrap_actor
|
9
|
+
@container_name = container_name
|
10
|
+
|
11
|
+
tell :monitor
|
12
|
+
end
|
13
|
+
|
14
|
+
def on_message(message)
|
15
|
+
if message == :monitor
|
16
|
+
MonitorDockerEvents.call(
|
17
|
+
container_name: @container_name,
|
18
|
+
handler: ->(event){ @bootstrap_actor << :bootstrap }
|
19
|
+
)
|
20
|
+
else
|
21
|
+
pass
|
22
|
+
end
|
23
|
+
end
|
24
|
+
end
|
25
|
+
end
|
@@ -0,0 +1,65 @@
|
|
1
|
+
require 'consul_bridge/base'
|
2
|
+
require 'consul_bridge/bootstrap_consul_actor'
|
3
|
+
require 'consul_bridge/monitor_docker_events_actor'
|
4
|
+
require 'concurrent'
|
5
|
+
|
6
|
+
module ConsulBridge
|
7
|
+
class RunBridge < Base
|
8
|
+
attr_accessor :bucket, :container_name, :join_all
|
9
|
+
|
10
|
+
def initialize(bucket:, container_name:, join_all: false)
|
11
|
+
self.bucket = bucket
|
12
|
+
self.container_name = container_name
|
13
|
+
self.join_all = join_all
|
14
|
+
end
|
15
|
+
|
16
|
+
def call
|
17
|
+
# Enable for actor debugging
|
18
|
+
# Concurrent.use_stdlib_logger(Logger::DEBUG)
|
19
|
+
self_read, self_write = IO.pipe
|
20
|
+
%w(INT TERM).each do |sig|
|
21
|
+
begin
|
22
|
+
trap sig do
|
23
|
+
self_write.puts(sig)
|
24
|
+
end
|
25
|
+
rescue ArgumentError
|
26
|
+
puts "Signal #{sig} not supported"
|
27
|
+
end
|
28
|
+
end
|
29
|
+
|
30
|
+
begin
|
31
|
+
bootstrap_actor = BootstrapConsulActor.spawn(
|
32
|
+
:bootstrap_consul,
|
33
|
+
bucket: self.bucket,
|
34
|
+
join_all: self.join_all
|
35
|
+
)
|
36
|
+
bootstrap_actor << :bootstrap
|
37
|
+
|
38
|
+
MonitorDockerEventsActor.spawn(
|
39
|
+
:monitor_docker_events,
|
40
|
+
bootstrap_actor: bootstrap_actor,
|
41
|
+
container_name: container_name
|
42
|
+
)
|
43
|
+
|
44
|
+
while readable_io = IO.select([self_read])
|
45
|
+
signal = readable_io.first[0].gets.strip
|
46
|
+
handle_signal(signal)
|
47
|
+
end
|
48
|
+
|
49
|
+
rescue Interrupt
|
50
|
+
puts 'Exiting'
|
51
|
+
# actors are cleaned up in at_exit handler
|
52
|
+
exit 0
|
53
|
+
end
|
54
|
+
end
|
55
|
+
|
56
|
+
def handle_signal(sig)
|
57
|
+
case sig
|
58
|
+
when 'INT'
|
59
|
+
raise Interrupt
|
60
|
+
when 'TERM'
|
61
|
+
raise Interrupt
|
62
|
+
end
|
63
|
+
end
|
64
|
+
end
|
65
|
+
end
|
metadata
ADDED
@@ -0,0 +1,194 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: consul_bridge
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Ryan Schlesinger
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2016-04-20 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: thor
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0.19'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0.19'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: excon
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 0.49.0
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 0.49.0
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: fog-aws
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0.9'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0.9'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: mime-types
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '3.0'
|
62
|
+
type: :runtime
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '3.0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: docker-api
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '1.28'
|
76
|
+
type: :runtime
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '1.28'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: concurrent-ruby
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '1.0'
|
90
|
+
type: :runtime
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '1.0'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: concurrent-ruby-edge
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - "~>"
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0.2'
|
104
|
+
type: :runtime
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - "~>"
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0.2'
|
111
|
+
- !ruby/object:Gem::Dependency
|
112
|
+
name: bundler
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - "~>"
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '1.11'
|
118
|
+
type: :development
|
119
|
+
prerelease: false
|
120
|
+
version_requirements: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - "~>"
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '1.11'
|
125
|
+
- !ruby/object:Gem::Dependency
|
126
|
+
name: rake
|
127
|
+
requirement: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - "~>"
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '10.0'
|
132
|
+
type: :development
|
133
|
+
prerelease: false
|
134
|
+
version_requirements: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - "~>"
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '10.0'
|
139
|
+
description:
|
140
|
+
email:
|
141
|
+
- ryan@outstand.com
|
142
|
+
executables:
|
143
|
+
- consul_bridge
|
144
|
+
extensions: []
|
145
|
+
extra_rdoc_files: []
|
146
|
+
files:
|
147
|
+
- ".gitignore"
|
148
|
+
- Dockerfile
|
149
|
+
- Gemfile
|
150
|
+
- README.md
|
151
|
+
- Rakefile
|
152
|
+
- bin/console
|
153
|
+
- bin/setup
|
154
|
+
- consul_bridge.gemspec
|
155
|
+
- docker-entrypoint.sh
|
156
|
+
- exe/consul_bridge
|
157
|
+
- lib/consul_bridge.rb
|
158
|
+
- lib/consul_bridge/base.rb
|
159
|
+
- lib/consul_bridge/bootstrap_consul.rb
|
160
|
+
- lib/consul_bridge/bootstrap_consul_actor.rb
|
161
|
+
- lib/consul_bridge/cli.rb
|
162
|
+
- lib/consul_bridge/detect_consul.rb
|
163
|
+
- lib/consul_bridge/detect_consul_bootstrap.rb
|
164
|
+
- lib/consul_bridge/download_masters.rb
|
165
|
+
- lib/consul_bridge/get_private_ip.rb
|
166
|
+
- lib/consul_bridge/join_consul.rb
|
167
|
+
- lib/consul_bridge/monitor_docker_events.rb
|
168
|
+
- lib/consul_bridge/monitor_docker_events_actor.rb
|
169
|
+
- lib/consul_bridge/run_bridge.rb
|
170
|
+
- lib/consul_bridge/version.rb
|
171
|
+
homepage: https://github.com/outstand/consul_bridge
|
172
|
+
licenses: []
|
173
|
+
metadata: {}
|
174
|
+
post_install_message:
|
175
|
+
rdoc_options: []
|
176
|
+
require_paths:
|
177
|
+
- lib
|
178
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
179
|
+
requirements:
|
180
|
+
- - ">="
|
181
|
+
- !ruby/object:Gem::Version
|
182
|
+
version: '0'
|
183
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
184
|
+
requirements:
|
185
|
+
- - ">="
|
186
|
+
- !ruby/object:Gem::Version
|
187
|
+
version: '0'
|
188
|
+
requirements: []
|
189
|
+
rubyforge_project:
|
190
|
+
rubygems_version: 2.4.8
|
191
|
+
signing_key:
|
192
|
+
specification_version: 4
|
193
|
+
summary: Discover consul master nodes and join local agent
|
194
|
+
test_files: []
|