firespring_dev_commands 2.1.0 → 2.1.1.pre.alpha.1
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a503e80f6ca42a9310361f9ecff5d1977eacaba76043acc678366af991b3a35c
|
4
|
+
data.tar.gz: 19cb2cabecd31b198de46bfbed9210954a9a733eaae49f16c43bf81ff3b58d1e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e2d32d0d9fbd06bff8a89b528ffb5e07ac814178c4c76036033ef62442ce6b99135951b02a8827cbe75e14adee439b2f2ddde456858d19118af14a7f8939465f
|
7
|
+
data.tar.gz: ab03be7074cb9aa64f29d0f177082b0a09cfff717790c83469fb23c1bcb047f6deaee131c94e39673bc0599692b9887edd4208c7a0385a930a460d0c4fa7832c
|
@@ -7,13 +7,7 @@ module Dev
|
|
7
7
|
attr_accessor :client
|
8
8
|
|
9
9
|
def initialize
|
10
|
-
@client =
|
11
|
-
end
|
12
|
-
|
13
|
-
# Create/set a new client if none is present
|
14
|
-
# Return the client
|
15
|
-
def client
|
16
|
-
@client ||= ::Aws::SSM::Client.new
|
10
|
+
@client = ::Aws::SSM::Client.new
|
17
11
|
end
|
18
12
|
|
19
13
|
# Get the value of the given parameter name
|
@@ -27,6 +21,32 @@ module Dev
|
|
27
21
|
rescue ::Aws::SSM::Errors::ParameterNotFound
|
28
22
|
raise "parameter #{name} does not exist in #{Dev::Aws::Profile.new.current}"
|
29
23
|
end
|
24
|
+
|
25
|
+
# Retrieve all parameters which start with the given path
|
26
|
+
def list(path, recursive: true, with_decryption: true)
|
27
|
+
next_token = nil
|
28
|
+
|
29
|
+
parameters = []
|
30
|
+
loop do
|
31
|
+
response = client.get_parameters_by_path(
|
32
|
+
path:,
|
33
|
+
recursive:,
|
34
|
+
with_decryption:,
|
35
|
+
next_token:
|
36
|
+
)
|
37
|
+
parameters += response.parameters
|
38
|
+
break unless (next_token = response.next_token)
|
39
|
+
end
|
40
|
+
parameters
|
41
|
+
end
|
42
|
+
|
43
|
+
# Sets the given parameter name's value to the given value
|
44
|
+
# Pass in additional params as desired
|
45
|
+
def put(name, value, **params)
|
46
|
+
params[:type] ||= 'String'
|
47
|
+
params[:overwrite] ||= true
|
48
|
+
client.put_parameter(name:, value:, **params)
|
49
|
+
end
|
30
50
|
end
|
31
51
|
end
|
32
52
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: firespring_dev_commands
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.1.pre.alpha.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Firespring
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-
|
11
|
+
date: 2023-08-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -329,9 +329,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
329
329
|
version: '3.1'
|
330
330
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
331
331
|
requirements:
|
332
|
-
- - "
|
332
|
+
- - ">"
|
333
333
|
- !ruby/object:Gem::Version
|
334
|
-
version:
|
334
|
+
version: 1.3.1
|
335
335
|
requirements: []
|
336
336
|
rubygems_version: 3.4.10
|
337
337
|
signing_key:
|