diplomat-scalp42 0.224
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/LICENSE +24 -0
- data/README.md +356 -0
- data/features/configuration.feature +9 -0
- data/features/step_definitions/setup_diplomat.rb +24 -0
- data/features/step_definitions/test_key_value.rb +9 -0
- data/lib/diplomat/acl.rb +81 -0
- data/lib/diplomat/agent.rb +42 -0
- data/lib/diplomat/check.rb +109 -0
- data/lib/diplomat/configuration.rb +28 -0
- data/lib/diplomat/datacenter.rb +21 -0
- data/lib/diplomat/error.rb +22 -0
- data/lib/diplomat/event.rb +166 -0
- data/lib/diplomat/health.rb +81 -0
- data/lib/diplomat/kv.rb +263 -0
- data/lib/diplomat/lock.rb +54 -0
- data/lib/diplomat/maintenance.rb +41 -0
- data/lib/diplomat/members.rb +14 -0
- data/lib/diplomat/node.rb +43 -0
- data/lib/diplomat/nodes.rb +22 -0
- data/lib/diplomat/policy.rb +112 -0
- data/lib/diplomat/query.rb +87 -0
- data/lib/diplomat/rest_client.rb +278 -0
- data/lib/diplomat/service.rb +111 -0
- data/lib/diplomat/session.rb +75 -0
- data/lib/diplomat/status.rb +22 -0
- data/lib/diplomat/token.rb +129 -0
- data/lib/diplomat/version.rb +3 -0
- data/lib/diplomat.rb +63 -0
- metadata +267 -0
@@ -0,0 +1,75 @@
|
|
1
|
+
module Diplomat
|
2
|
+
# Methods for interacting with the Consul session API endpoint
|
3
|
+
class Session < Diplomat::RestClient
|
4
|
+
@access_methods = %i[create destroy list renew info node]
|
5
|
+
|
6
|
+
# Create a new session
|
7
|
+
# @param value [Object] hash or json representation of the session arguments
|
8
|
+
# @param options [Hash] session options
|
9
|
+
# @return [String] The sesssion id
|
10
|
+
def create(value = nil, options = {})
|
11
|
+
# TODO: only certain keys are recognised in a session create request,
|
12
|
+
# should raise an error on others.
|
13
|
+
custom_params = []
|
14
|
+
custom_params << use_named_parameter('dc', options[:dc]) if options[:dc]
|
15
|
+
data = value.is_a?(String) ? value : JSON.generate(value) unless value.nil?
|
16
|
+
raw = send_put_request(@conn, ['/v1/session/create'], options, data, custom_params)
|
17
|
+
body = JSON.parse(raw.body)
|
18
|
+
body['ID']
|
19
|
+
end
|
20
|
+
|
21
|
+
# Destroy a session
|
22
|
+
# @param id [String] session id
|
23
|
+
# @param options [Hash] session options
|
24
|
+
# @return [String] Success or failure of the session destruction
|
25
|
+
def destroy(id, options = {})
|
26
|
+
custom_params = []
|
27
|
+
custom_params << use_named_parameter('dc', options[:dc]) if options[:dc]
|
28
|
+
raw = send_put_request(@conn, ["/v1/session/destroy/#{id}"], options, nil, custom_params)
|
29
|
+
raw.body
|
30
|
+
end
|
31
|
+
|
32
|
+
# List sessions
|
33
|
+
# @param options [Hash] session options
|
34
|
+
# @return [OpenStruct]
|
35
|
+
def list(options = {})
|
36
|
+
custom_params = []
|
37
|
+
custom_params << use_named_parameter('dc', options[:dc]) if options[:dc]
|
38
|
+
raw = send_get_request(@conn, ['/v1/session/list'], options, custom_params)
|
39
|
+
JSON.parse(raw.body).map { |session| OpenStruct.new session }
|
40
|
+
end
|
41
|
+
|
42
|
+
# Renew session
|
43
|
+
# @param id [String] session id
|
44
|
+
# @param options [Hash] session options
|
45
|
+
# @return [OpenStruct]
|
46
|
+
def renew(id, options = {})
|
47
|
+
custom_params = []
|
48
|
+
custom_params << use_named_parameter('dc', options[:dc]) if options[:dc]
|
49
|
+
raw = send_put_request(@conn, ["/v1/session/renew/#{id}"], options, nil, custom_params)
|
50
|
+
JSON.parse(raw.body).map { |session| OpenStruct.new session }
|
51
|
+
end
|
52
|
+
|
53
|
+
# Session information
|
54
|
+
# @param id [String] session id
|
55
|
+
# @param options [Hash] session options
|
56
|
+
# @return [OpenStruct]
|
57
|
+
def info(id, options = {})
|
58
|
+
custom_params = []
|
59
|
+
custom_params << use_named_parameter('dc', options[:dc]) if options[:dc]
|
60
|
+
raw = send_get_request(@conn, ["/v1/session/info/#{id}"], options, custom_params)
|
61
|
+
JSON.parse(raw.body).map { |session| OpenStruct.new session }
|
62
|
+
end
|
63
|
+
|
64
|
+
# Session information for a given node
|
65
|
+
# @param name [String] node name
|
66
|
+
# @param options [Hash] session options
|
67
|
+
# @return [OpenStruct]
|
68
|
+
def node(name, options = {})
|
69
|
+
custom_params = []
|
70
|
+
custom_params << use_named_parameter('dc', options[:dc]) if options[:dc]
|
71
|
+
raw = send_get_request(@conn, ["/v1/session/node/#{name}"], options, custom_params)
|
72
|
+
JSON.parse(raw.body).map { |session| OpenStruct.new session }
|
73
|
+
end
|
74
|
+
end
|
75
|
+
end
|
@@ -0,0 +1,22 @@
|
|
1
|
+
module Diplomat
|
2
|
+
# Methods for interacting with the Consul status API endpoints, leader and peers
|
3
|
+
class Status < Diplomat::RestClient
|
4
|
+
@access_methods = %i[leader peers]
|
5
|
+
|
6
|
+
# Get the raft leader for the datacenter in which the local consul agent is running
|
7
|
+
# @param options [Hash] options parameter hash
|
8
|
+
# @return [OpenStruct] the address of the leader
|
9
|
+
def leader(options = {})
|
10
|
+
ret = send_get_request(@conn, ['/v1/status/leader'], options)
|
11
|
+
JSON.parse(ret.body)
|
12
|
+
end
|
13
|
+
|
14
|
+
# Get an array of Raft peers for the datacenter in which the agent is running
|
15
|
+
# @param options [Hash] options parameter hash
|
16
|
+
# @return [OpenStruct] an array of peers
|
17
|
+
def peers(options = {})
|
18
|
+
ret = send_get_request(@conn, ['/v1/status/peers'], options)
|
19
|
+
JSON.parse(ret.body)
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
@@ -0,0 +1,129 @@
|
|
1
|
+
module Diplomat
|
2
|
+
# Methods for interacting with the Consul ACL Policy API endpoint
|
3
|
+
class Token < Diplomat::RestClient
|
4
|
+
@access_methods = %i[list read create delete update clone self]
|
5
|
+
attr_reader :id, :type, :acl
|
6
|
+
|
7
|
+
# Read ACL token with the given Accessor ID
|
8
|
+
# @param id [String] accessor ID of the ACL token to read
|
9
|
+
# @param options [Hash] options parameter hash
|
10
|
+
# @return [Hash] existing ACL token
|
11
|
+
# rubocop:disable PerceivedComplexity
|
12
|
+
def read(id, options = {}, not_found = :reject, found = :return)
|
13
|
+
@options = options
|
14
|
+
custom_params = []
|
15
|
+
custom_params << use_consistency(options)
|
16
|
+
|
17
|
+
@raw = send_get_request(@conn_no_err, ["/v1/acl/token/#{id}"], options, custom_params)
|
18
|
+
|
19
|
+
if @raw.status == 200 && @raw.body.chomp != 'null'
|
20
|
+
case found
|
21
|
+
when :reject
|
22
|
+
raise Diplomat::AclNotFound, id
|
23
|
+
when :return
|
24
|
+
return parse_body
|
25
|
+
end
|
26
|
+
elsif @raw.status == 403
|
27
|
+
case not_found
|
28
|
+
when :reject
|
29
|
+
raise Diplomat::AclNotFound, id
|
30
|
+
when :return
|
31
|
+
return nil
|
32
|
+
end
|
33
|
+
else
|
34
|
+
raise Diplomat::UnknownStatus, "status #{@raw.status}: #{@raw.body}"
|
35
|
+
end
|
36
|
+
end
|
37
|
+
# rubocop:enable PerceivedComplexity
|
38
|
+
|
39
|
+
# List all the ACL tokens
|
40
|
+
# @param policy [String] filters the token list matching the specific policy ID
|
41
|
+
# @param options [Hash] options parameter hash
|
42
|
+
# @return [List] list of [Hash] of ACL tokens
|
43
|
+
def list(policy = nil, options = {})
|
44
|
+
custom_params = []
|
45
|
+
custom_params << use_named_parameter('policy', policy) if policy
|
46
|
+
@raw = send_get_request(@conn_no_err, ['/v1/acl/tokens'], options, custom_params)
|
47
|
+
raise Diplomat::AclNotFound if @raw.status == 403
|
48
|
+
|
49
|
+
parse_body
|
50
|
+
end
|
51
|
+
|
52
|
+
# Update an existing ACL token
|
53
|
+
# @param value [Hash] ACL token definition, AccessorID is mandatory
|
54
|
+
# @param options [Hash] options parameter hash
|
55
|
+
# @return [Hash] result ACL token
|
56
|
+
def update(value, options = {})
|
57
|
+
id = value[:AccessorID] || value['AccessorID']
|
58
|
+
raise Diplomat::AccessorIdParameterRequired if id.nil?
|
59
|
+
|
60
|
+
custom_params = use_cas(@options)
|
61
|
+
@raw = send_put_request(@conn, ["/v1/acl/token/#{id}"], options, value, custom_params)
|
62
|
+
if @raw.status == 200
|
63
|
+
parse_body
|
64
|
+
elsif @raw.status == 403
|
65
|
+
raise Diplomat::AclNotFound, id
|
66
|
+
elsif @raw.status == 400
|
67
|
+
raise Diplomat::TokenMalformed, @raw.body
|
68
|
+
else
|
69
|
+
raise Diplomat::UnknownStatus, "status #{@raw.status}: #{@raw.body}"
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
# Create a new ACL token
|
74
|
+
# @param value [Hash] ACL token definition
|
75
|
+
# @param options [Hash] options parameter hash
|
76
|
+
# @return [Hash] new ACL token
|
77
|
+
def create(value, options = {})
|
78
|
+
id = value[:AccessorID] || value['AccessorID']
|
79
|
+
raise Diplomat::TokenMalformed if id
|
80
|
+
|
81
|
+
custom_params = use_cas(@options)
|
82
|
+
@raw = send_put_request(@conn, ['/v1/acl/token'], options, value, custom_params)
|
83
|
+
return parse_body if @raw.status == 200
|
84
|
+
|
85
|
+
raise Diplomat::UnknownStatus, "status #{@raw.status}: #{@raw.body}"
|
86
|
+
end
|
87
|
+
|
88
|
+
# Delete an existing ACL token
|
89
|
+
# @param id [String] UUID of the ACL token to delete
|
90
|
+
# @param options [Hash] options parameter hash
|
91
|
+
# @return [Bool]
|
92
|
+
def delete(id, options = {})
|
93
|
+
@raw = send_delete_request(@conn, ["/v1/acl/token/#{id}"], options, nil)
|
94
|
+
@raw.body.chomp == 'true'
|
95
|
+
end
|
96
|
+
|
97
|
+
# Clone an existing ACL token
|
98
|
+
# @param value [Hash] ACL token definition, AccessorID is mandatory
|
99
|
+
# @param options [Hash] options parameter hash
|
100
|
+
# @return [Hash] cloned ACL token
|
101
|
+
def clone(value, options = {})
|
102
|
+
id = value[:AccessorID] || value['AccessorID']
|
103
|
+
raise Diplomat::AccessorIdParameterRequired if id.nil?
|
104
|
+
|
105
|
+
custom_params = use_cas(@options)
|
106
|
+
@raw = send_put_request(@conn, ["/v1/acl/token/#{id}/clone"], options, value, custom_params)
|
107
|
+
if @raw.status == 200
|
108
|
+
parse_body
|
109
|
+
elsif @raw.status == 403
|
110
|
+
raise Diplomat::AclNotFound, id
|
111
|
+
else
|
112
|
+
raise Diplomat::UnknownStatus, "status #{@raw.status}: #{@raw.body}"
|
113
|
+
end
|
114
|
+
end
|
115
|
+
|
116
|
+
# Returns ACL token details matching X-Consul-Token header
|
117
|
+
# @param options [Hash] options parameter hash
|
118
|
+
# @return [Hash] ACL token
|
119
|
+
def self(options = {})
|
120
|
+
custom_params = use_cas(@options)
|
121
|
+
@raw = send_get_request(@conn, ['/v1/acl/token/self'], options, custom_params)
|
122
|
+
if @raw.status == 200
|
123
|
+
parse_body
|
124
|
+
elsif @raw.status == 403
|
125
|
+
raise Diplomat::AclNotFound, id
|
126
|
+
end
|
127
|
+
end
|
128
|
+
end
|
129
|
+
end
|
data/lib/diplomat.rb
ADDED
@@ -0,0 +1,63 @@
|
|
1
|
+
require 'json'
|
2
|
+
require 'base64'
|
3
|
+
require 'faraday'
|
4
|
+
|
5
|
+
# Top level namespace ensures all required libraries are included and initializes the gem configration.
|
6
|
+
module Diplomat
|
7
|
+
class << self
|
8
|
+
attr_accessor :root_path
|
9
|
+
attr_accessor :lib_path
|
10
|
+
attr_accessor :configuration
|
11
|
+
|
12
|
+
# Internal: Requires internal Faraday libraries.
|
13
|
+
# @param *libs One or more relative String names to Faraday classes.
|
14
|
+
# @return [nil]
|
15
|
+
def require_libs(*libs)
|
16
|
+
libs.each do |lib|
|
17
|
+
require "#{lib_path}/#{lib}"
|
18
|
+
end
|
19
|
+
end
|
20
|
+
|
21
|
+
alias require_lib require_libs
|
22
|
+
end
|
23
|
+
|
24
|
+
raise 'Diplomat only supports ruby >= 2.0.0' unless RUBY_VERSION.to_f >= 2.0
|
25
|
+
|
26
|
+
self.root_path = File.expand_path __dir__
|
27
|
+
self.lib_path = File.expand_path 'diplomat', __dir__
|
28
|
+
|
29
|
+
require_libs 'configuration', 'rest_client', 'kv', 'datacenter', 'service',
|
30
|
+
'members', 'node', 'nodes', 'check', 'health', 'session', 'lock',
|
31
|
+
'error', 'event', 'acl', 'maintenance', 'query', 'agent', 'status',
|
32
|
+
'policy', 'token'
|
33
|
+
self.configuration ||= Diplomat::Configuration.new
|
34
|
+
|
35
|
+
class << self
|
36
|
+
# Build optional configuration by yielding a block to configure
|
37
|
+
# @yield [Diplomat::Configuration]
|
38
|
+
def configure
|
39
|
+
self.configuration ||= Diplomat::Configuration.new
|
40
|
+
yield(configuration)
|
41
|
+
end
|
42
|
+
|
43
|
+
private
|
44
|
+
|
45
|
+
# Send all other unknown commands to Diplomat::Kv
|
46
|
+
# @deprecated Please use Diplomat::Kv instead.
|
47
|
+
# @param name [Symbol] Method to send to Kv
|
48
|
+
# @param *args List of arguments to send to Kv
|
49
|
+
# @param &block block to send to Kv
|
50
|
+
# @return [Object]
|
51
|
+
def method_missing(name, *args, &block)
|
52
|
+
Diplomat::Kv.new.send(name, *args, &block) || super
|
53
|
+
end
|
54
|
+
|
55
|
+
# Make `respond_to_missing?` fall back to super
|
56
|
+
#
|
57
|
+
# @param meth_id [Symbol] the tested method
|
58
|
+
# @oaram with_private if private methods should be tested too
|
59
|
+
def respond_to_missing?(meth_id, with_private = false)
|
60
|
+
access_method?(meth_id) || super
|
61
|
+
end
|
62
|
+
end
|
63
|
+
end
|
metadata
ADDED
@@ -0,0 +1,267 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: diplomat-scalp42
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: '0.224'
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- John Hamelink
|
8
|
+
- Trevor Wood
|
9
|
+
autorequire:
|
10
|
+
bindir: bin
|
11
|
+
cert_chain: []
|
12
|
+
date: 2019-05-02 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
15
|
+
name: bundler
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
17
|
+
requirements:
|
18
|
+
- - "~>"
|
19
|
+
- !ruby/object:Gem::Version
|
20
|
+
version: '2.0'
|
21
|
+
- - ">="
|
22
|
+
- !ruby/object:Gem::Version
|
23
|
+
version: 2.0.1
|
24
|
+
type: :development
|
25
|
+
prerelease: false
|
26
|
+
version_requirements: !ruby/object:Gem::Requirement
|
27
|
+
requirements:
|
28
|
+
- - "~>"
|
29
|
+
- !ruby/object:Gem::Version
|
30
|
+
version: '2.0'
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: 2.0.1
|
34
|
+
- !ruby/object:Gem::Dependency
|
35
|
+
name: codeclimate-test-reporter
|
36
|
+
requirement: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: 0.4.0
|
41
|
+
type: :development
|
42
|
+
prerelease: false
|
43
|
+
version_requirements: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: 0.4.0
|
48
|
+
- !ruby/object:Gem::Dependency
|
49
|
+
name: cucumber
|
50
|
+
requirement: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '2.0'
|
55
|
+
type: :development
|
56
|
+
prerelease: false
|
57
|
+
version_requirements: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '2.0'
|
62
|
+
- !ruby/object:Gem::Dependency
|
63
|
+
name: fakes-rspec
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '2.1'
|
69
|
+
type: :development
|
70
|
+
prerelease: false
|
71
|
+
version_requirements: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '2.1'
|
76
|
+
- !ruby/object:Gem::Dependency
|
77
|
+
name: fivemat
|
78
|
+
requirement: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '1.3'
|
83
|
+
type: :development
|
84
|
+
prerelease: false
|
85
|
+
version_requirements: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '1.3'
|
90
|
+
- !ruby/object:Gem::Dependency
|
91
|
+
name: gem-release
|
92
|
+
requirement: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0.7'
|
97
|
+
type: :development
|
98
|
+
prerelease: false
|
99
|
+
version_requirements: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - "~>"
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0.7'
|
104
|
+
- !ruby/object:Gem::Dependency
|
105
|
+
name: pry
|
106
|
+
requirement: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - "~>"
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0.9'
|
111
|
+
type: :development
|
112
|
+
prerelease: false
|
113
|
+
version_requirements: !ruby/object:Gem::Requirement
|
114
|
+
requirements:
|
115
|
+
- - "~>"
|
116
|
+
- !ruby/object:Gem::Version
|
117
|
+
version: '0.9'
|
118
|
+
- !ruby/object:Gem::Dependency
|
119
|
+
name: rake
|
120
|
+
requirement: !ruby/object:Gem::Requirement
|
121
|
+
requirements:
|
122
|
+
- - "~>"
|
123
|
+
- !ruby/object:Gem::Version
|
124
|
+
version: '12.0'
|
125
|
+
type: :development
|
126
|
+
prerelease: false
|
127
|
+
version_requirements: !ruby/object:Gem::Requirement
|
128
|
+
requirements:
|
129
|
+
- - "~>"
|
130
|
+
- !ruby/object:Gem::Version
|
131
|
+
version: '12.0'
|
132
|
+
- !ruby/object:Gem::Dependency
|
133
|
+
name: rspec
|
134
|
+
requirement: !ruby/object:Gem::Requirement
|
135
|
+
requirements:
|
136
|
+
- - "~>"
|
137
|
+
- !ruby/object:Gem::Version
|
138
|
+
version: '3.2'
|
139
|
+
type: :development
|
140
|
+
prerelease: false
|
141
|
+
version_requirements: !ruby/object:Gem::Requirement
|
142
|
+
requirements:
|
143
|
+
- - "~>"
|
144
|
+
- !ruby/object:Gem::Version
|
145
|
+
version: '3.2'
|
146
|
+
- !ruby/object:Gem::Dependency
|
147
|
+
name: rubocop
|
148
|
+
requirement: !ruby/object:Gem::Requirement
|
149
|
+
requirements:
|
150
|
+
- - "~>"
|
151
|
+
- !ruby/object:Gem::Version
|
152
|
+
version: '0.49'
|
153
|
+
type: :development
|
154
|
+
prerelease: false
|
155
|
+
version_requirements: !ruby/object:Gem::Requirement
|
156
|
+
requirements:
|
157
|
+
- - "~>"
|
158
|
+
- !ruby/object:Gem::Version
|
159
|
+
version: '0.49'
|
160
|
+
- !ruby/object:Gem::Dependency
|
161
|
+
name: webmock
|
162
|
+
requirement: !ruby/object:Gem::Requirement
|
163
|
+
requirements:
|
164
|
+
- - ">="
|
165
|
+
- !ruby/object:Gem::Version
|
166
|
+
version: '0'
|
167
|
+
type: :development
|
168
|
+
prerelease: false
|
169
|
+
version_requirements: !ruby/object:Gem::Requirement
|
170
|
+
requirements:
|
171
|
+
- - ">="
|
172
|
+
- !ruby/object:Gem::Version
|
173
|
+
version: '0'
|
174
|
+
- !ruby/object:Gem::Dependency
|
175
|
+
name: deep_merge
|
176
|
+
requirement: !ruby/object:Gem::Requirement
|
177
|
+
requirements:
|
178
|
+
- - "~>"
|
179
|
+
- !ruby/object:Gem::Version
|
180
|
+
version: '1.0'
|
181
|
+
- - ">="
|
182
|
+
- !ruby/object:Gem::Version
|
183
|
+
version: 1.0.1
|
184
|
+
type: :runtime
|
185
|
+
prerelease: false
|
186
|
+
version_requirements: !ruby/object:Gem::Requirement
|
187
|
+
requirements:
|
188
|
+
- - "~>"
|
189
|
+
- !ruby/object:Gem::Version
|
190
|
+
version: '1.0'
|
191
|
+
- - ">="
|
192
|
+
- !ruby/object:Gem::Version
|
193
|
+
version: 1.0.1
|
194
|
+
- !ruby/object:Gem::Dependency
|
195
|
+
name: faraday
|
196
|
+
requirement: !ruby/object:Gem::Requirement
|
197
|
+
requirements:
|
198
|
+
- - "~>"
|
199
|
+
- !ruby/object:Gem::Version
|
200
|
+
version: '0.9'
|
201
|
+
type: :runtime
|
202
|
+
prerelease: false
|
203
|
+
version_requirements: !ruby/object:Gem::Requirement
|
204
|
+
requirements:
|
205
|
+
- - "~>"
|
206
|
+
- !ruby/object:Gem::Version
|
207
|
+
version: '0.9'
|
208
|
+
description: Diplomat is a simple wrapper for Consul
|
209
|
+
email:
|
210
|
+
- john@johnhamelink.com
|
211
|
+
- trevor.g.wood@gmail.com
|
212
|
+
executables: []
|
213
|
+
extensions: []
|
214
|
+
extra_rdoc_files: []
|
215
|
+
files:
|
216
|
+
- LICENSE
|
217
|
+
- README.md
|
218
|
+
- features/configuration.feature
|
219
|
+
- features/step_definitions/setup_diplomat.rb
|
220
|
+
- features/step_definitions/test_key_value.rb
|
221
|
+
- lib/diplomat.rb
|
222
|
+
- lib/diplomat/acl.rb
|
223
|
+
- lib/diplomat/agent.rb
|
224
|
+
- lib/diplomat/check.rb
|
225
|
+
- lib/diplomat/configuration.rb
|
226
|
+
- lib/diplomat/datacenter.rb
|
227
|
+
- lib/diplomat/error.rb
|
228
|
+
- lib/diplomat/event.rb
|
229
|
+
- lib/diplomat/health.rb
|
230
|
+
- lib/diplomat/kv.rb
|
231
|
+
- lib/diplomat/lock.rb
|
232
|
+
- lib/diplomat/maintenance.rb
|
233
|
+
- lib/diplomat/members.rb
|
234
|
+
- lib/diplomat/node.rb
|
235
|
+
- lib/diplomat/nodes.rb
|
236
|
+
- lib/diplomat/policy.rb
|
237
|
+
- lib/diplomat/query.rb
|
238
|
+
- lib/diplomat/rest_client.rb
|
239
|
+
- lib/diplomat/service.rb
|
240
|
+
- lib/diplomat/session.rb
|
241
|
+
- lib/diplomat/status.rb
|
242
|
+
- lib/diplomat/token.rb
|
243
|
+
- lib/diplomat/version.rb
|
244
|
+
homepage: https://github.com/WeAreFarmGeek/diplomat
|
245
|
+
licenses:
|
246
|
+
- BSD-3-Clause
|
247
|
+
metadata: {}
|
248
|
+
post_install_message:
|
249
|
+
rdoc_options: []
|
250
|
+
require_paths:
|
251
|
+
- lib
|
252
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
253
|
+
requirements:
|
254
|
+
- - ">="
|
255
|
+
- !ruby/object:Gem::Version
|
256
|
+
version: '0'
|
257
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
258
|
+
requirements:
|
259
|
+
- - ">="
|
260
|
+
- !ruby/object:Gem::Version
|
261
|
+
version: '0'
|
262
|
+
requirements: []
|
263
|
+
rubygems_version: 3.0.3
|
264
|
+
signing_key:
|
265
|
+
specification_version: 4
|
266
|
+
summary: Diplomat is a simple wrapper for Consul
|
267
|
+
test_files: []
|