container_config 0.1.3 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/Gemfile.lock +7 -7
- data/lib/container_config/redis.rb +2 -0
- data/lib/container_config/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4e3fa143d884c4e9e718054a02b5964a50f33b8bf8b20412d019f1f823b55bd4
|
4
|
+
data.tar.gz: f59be34caf1427460dcacc5a9155a930b90ac8f795fc9cca526072381708255a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 105ba644ae63e6408ae1cb158916f85ff845a1997c29bbedce410afaf2d7f76e96e81a8080982127c245db7ac8e0b0bddc3a3a7c6db34ca18ece64e2c2a92692
|
7
|
+
data.tar.gz: 4180e29ad6571020d5e5720fefa06ccb1ae9ba71860ad1ed45018bd58314b2f0f013bc2bd5272b7f457b7b10b9bd2188e43b3d45c17207fe85ac48253d6b6967
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
container_config (0.
|
4
|
+
container_config (0.2.0)
|
5
5
|
|
6
6
|
GEM
|
7
7
|
remote: https://rubygems.org/
|
@@ -9,10 +9,10 @@ GEM
|
|
9
9
|
ast (2.4.2)
|
10
10
|
diff-lcs (1.4.4)
|
11
11
|
parallel (1.20.1)
|
12
|
-
parser (3.0.
|
12
|
+
parser (3.0.2.0)
|
13
13
|
ast (~> 2.4.1)
|
14
14
|
rainbow (3.0.0)
|
15
|
-
rake (13.0.
|
15
|
+
rake (13.0.6)
|
16
16
|
regexp_parser (2.1.1)
|
17
17
|
rexml (3.2.5)
|
18
18
|
rspec (3.10.0)
|
@@ -28,7 +28,7 @@ GEM
|
|
28
28
|
diff-lcs (>= 1.2.0, < 2.0)
|
29
29
|
rspec-support (~> 3.10.0)
|
30
30
|
rspec-support (3.10.2)
|
31
|
-
rubocop (1.
|
31
|
+
rubocop (1.18.3)
|
32
32
|
parallel (~> 1.10)
|
33
33
|
parser (>= 3.0.0.0)
|
34
34
|
rainbow (>= 2.2.2, < 4.0)
|
@@ -37,10 +37,10 @@ GEM
|
|
37
37
|
rubocop-ast (>= 1.7.0, < 2.0)
|
38
38
|
ruby-progressbar (~> 1.7)
|
39
39
|
unicode-display_width (>= 1.4.0, < 3.0)
|
40
|
-
rubocop-ast (1.
|
40
|
+
rubocop-ast (1.8.0)
|
41
41
|
parser (>= 3.0.1.1)
|
42
|
-
rubocop-rake (0.
|
43
|
-
rubocop
|
42
|
+
rubocop-rake (0.6.0)
|
43
|
+
rubocop (~> 1.0)
|
44
44
|
rubocop-rspec (2.4.0)
|
45
45
|
rubocop (~> 1.0)
|
46
46
|
rubocop-ast (>= 1.1.0)
|
@@ -23,12 +23,14 @@ module ContainerConfig
|
|
23
23
|
url = ContainerConfig.load("#{key}_URL", **options, default: "redis://#{host}:#{port}")
|
24
24
|
sentinels = sentinel_info(key, **options)
|
25
25
|
password = ContainerConfig.load("#{key}_PASSWORD", **options)
|
26
|
+
db = ContainerConfig.load("#{key}_DB", **options, type: :integer, coerce_nil: false)
|
26
27
|
|
27
28
|
# Ensure we never pass an empty string to Redis since it will be passed to the Redis AUTH
|
28
29
|
# command as-is and will cause an exception
|
29
30
|
password = nil if password.to_s.strip.empty?
|
30
31
|
|
31
32
|
redis_config = { url: url, password: password }
|
33
|
+
redis_config[:db] = db if db
|
32
34
|
redis_config[:sentinels] = sentinels unless sentinels.empty?
|
33
35
|
|
34
36
|
# Add SSL configuration
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: container_config
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matthew Newell
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-07-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|