flipper-consul 0.1.3 → 0.1.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +4 -4
- data/Vagrantfile +6 -6
- data/flipper-consul.gemspec +2 -2
- data/lib/flipper/adapters/consul.rb +3 -3
- data/lib/flipper/adapters/consul/version.rb +1 -1
- data/spec/flipper/consul_spec.rb +1 -1
- data/spec/helper.rb +1 -1
- metadata +7 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: edadf932ef4557ce85ddaa2d2a4987c95bd70aae
|
4
|
+
data.tar.gz: 65c90fbd9e6ad47c50076366f95b130890ab4804
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 17648471c2d4b0e352eeb340a9e8d1d6ad1eabeadbe6e2348284ff6b3a3c6cc4bb14245ddbbef3f88e1c7ca2242a175f4fbcf6b683d794031135756966956390
|
7
|
+
data.tar.gz: bd5a148b9653ec6fb8ec58719906cd75f97b44940e18e7d075fa726949beea848cb1face2c09d4ee852cc4d420c20d2cb7b9795d8c2f5ca7fcca0de6fa33ee00
|
data/.travis.yml
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
dist: trusty
|
1
2
|
language: ruby
|
2
3
|
rvm:
|
3
4
|
- 2.0.0
|
@@ -8,12 +9,11 @@ rvm:
|
|
8
9
|
gemfile: gemfiles/flipper-consul.gemfile
|
9
10
|
|
10
11
|
env:
|
11
|
-
- FLIPPER_VERSION: 0.
|
12
|
-
- FLIPPER_VERSION:
|
13
|
-
- FLIPPER_VERSION: 0.7.5
|
12
|
+
- FLIPPER_VERSION: 0.10.2
|
13
|
+
- FLIPPER_VERSION: 0.9.2
|
14
14
|
|
15
15
|
before_script:
|
16
|
-
- wget 'https://releases.hashicorp.com/consul/0.
|
16
|
+
- wget 'https://releases.hashicorp.com/consul/0.7.4/consul_0.7.4_linux_amd64.zip' --output-document=consul.zip
|
17
17
|
- unzip 'consul.zip'
|
18
18
|
- ./consul --version
|
19
19
|
|
data/Vagrantfile
CHANGED
@@ -1,20 +1,20 @@
|
|
1
1
|
# -*- mode: ruby -*-
|
2
2
|
# vi: set ft=ruby :
|
3
|
+
|
4
|
+
CONSUL_VERSION = '0.7.4'
|
5
|
+
|
3
6
|
Vagrant.configure(2) do |config|
|
4
|
-
config.vm.box = "
|
7
|
+
config.vm.box = "opscode-ubuntu-14.04"
|
5
8
|
config.vm.network "forwarded_port", guest: 8500, host: 8500
|
6
9
|
config.vm.provision "shell", inline: <<-SHELL
|
7
10
|
sudo apt-get update
|
8
11
|
sudo apt-get install unzip
|
9
12
|
|
10
|
-
wget
|
13
|
+
wget "https://releases.hashicorp.com/consul/#{CONSUL_VERSION}/consul_#{CONSUL_VERSION}_linux_amd64.zip" --output-document=consul.zip
|
11
14
|
unzip consul.zip
|
12
15
|
sudo chmod +x consul
|
13
16
|
sudo mv consul /usr/bin/consul
|
14
17
|
|
15
|
-
|
16
|
-
unzip ui.zip
|
17
|
-
|
18
|
-
consul agent -server -client 0.0.0.0 -bootstrap-expect 1 -data-dir /tmp/consul -ui-dir /home/vagrant/dist > /var/log/consul.log 2>&1 &
|
18
|
+
consul agent -server -client 0.0.0.0 -data-dir /tmp/consul -bootstrap-expect 1 -ui -dc dev04 > /var/log/consul.log 2>&1 &
|
19
19
|
SHELL
|
20
20
|
end
|
data/flipper-consul.gemspec
CHANGED
@@ -15,6 +15,6 @@ Gem::Specification.new do |spec|
|
|
15
15
|
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
16
16
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
17
17
|
|
18
|
-
spec.add_dependency 'flipper', '~> 0.
|
19
|
-
spec.add_dependency 'diplomat', '~> 1.
|
18
|
+
spec.add_dependency 'flipper', '~> 0.9'
|
19
|
+
spec.add_dependency 'diplomat', '~> 1.2'
|
20
20
|
end
|
@@ -49,7 +49,7 @@ module Flipper
|
|
49
49
|
|
50
50
|
# Public: Clears the gate values for a feature.
|
51
51
|
def clear(feature)
|
52
|
-
@client.delete build_path
|
52
|
+
@client.delete build_path(feature.key), recurse: true
|
53
53
|
true
|
54
54
|
end
|
55
55
|
|
@@ -104,7 +104,7 @@ module Flipper
|
|
104
104
|
def disable(feature, gate, thing)
|
105
105
|
case gate.data_type
|
106
106
|
when :boolean
|
107
|
-
@client.delete build_path
|
107
|
+
@client.delete build_path(feature), recurse: true
|
108
108
|
when :integer
|
109
109
|
@client.put key(feature, gate), thing.value.to_s
|
110
110
|
when :set
|
@@ -156,7 +156,7 @@ module Flipper
|
|
156
156
|
values = @client.raw
|
157
157
|
result = {}
|
158
158
|
values.each do |item|
|
159
|
-
result[item['Key'].sub!("#{key_path}/", '')] =
|
159
|
+
result[item['Key'].sub!("#{key_path}/", '')] = item['Value']
|
160
160
|
end
|
161
161
|
result
|
162
162
|
rescue Diplomat::KeyNotFound
|
data/spec/flipper/consul_spec.rb
CHANGED
data/spec/helper.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: flipper-consul
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Graham Davison
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2017-02-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: flipper
|
@@ -16,28 +16,28 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '0.
|
19
|
+
version: '0.9'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '0.
|
26
|
+
version: '0.9'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: diplomat
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '1.
|
33
|
+
version: '1.2'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '1.
|
40
|
+
version: '1.2'
|
41
41
|
description: Consul adapter for Flipper
|
42
42
|
email:
|
43
43
|
- g.m.davison@computer.org
|
@@ -81,11 +81,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
81
81
|
version: '0'
|
82
82
|
requirements: []
|
83
83
|
rubyforge_project:
|
84
|
-
rubygems_version: 2.6.
|
84
|
+
rubygems_version: 2.6.8
|
85
85
|
signing_key:
|
86
86
|
specification_version: 4
|
87
87
|
summary: Consul adapter for Flipper
|
88
88
|
test_files:
|
89
89
|
- spec/flipper/consul_spec.rb
|
90
90
|
- spec/helper.rb
|
91
|
-
has_rdoc:
|