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: bc0c3856d6d9cce9b429f158ace60d901d373a5ea8067645285e8a3a21bc3d5b
4
- data.tar.gz: c280047c0fc07d28a2aadfb7f554c19c3ddb80957d875988a67885d2222e83ae
3
+ metadata.gz: a503e80f6ca42a9310361f9ecff5d1977eacaba76043acc678366af991b3a35c
4
+ data.tar.gz: 19cb2cabecd31b198de46bfbed9210954a9a733eaae49f16c43bf81ff3b58d1e
5
5
  SHA512:
6
- metadata.gz: f7f7b2a1723ca77b297f4d252f178958e2841ecc665613863cfbb3b20c120dcfad3aa6f96c036f8404ad1f6fb188b22182d9d5f961922de0b0f12d1d7c957332
7
- data.tar.gz: d4f65836fe4afddbe6b97a39f5df1bc01e38e6b394bb8763751bfd8a373cbdfae0ad4f96cf744aed5543d783f78f5d283b556d4d1567dd2532d9e1bf671f3979
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 = nil
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
@@ -6,6 +6,6 @@ module Dev
6
6
  # Use 'v.v.v.pre.alpha.v' for pre-release vesions
7
7
  # Use 'v.v.v.beta.v for beta versions
8
8
  # Use semantic versioning for any releases (https://semver.org/)
9
- VERSION = '2.1.0'.freeze
9
+ VERSION = '2.1.1.pre.alpha.1'.freeze
10
10
  end
11
11
  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.0
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-07-27 00:00:00.000000000 Z
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: '0'
334
+ version: 1.3.1
335
335
  requirements: []
336
336
  rubygems_version: 3.4.10
337
337
  signing_key: