aws-sesocio-secrets 0.1.13 → 0.1.17
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/Gemfile.lock +11 -10
- data/lib/aws/sesocio/secrets.rb +10 -10
- data/lib/aws/sesocio/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 43cafab1821809e54353d6eb739fb5c3fb248b32464aadc331fe74f2f29f6645
|
4
|
+
data.tar.gz: e945228bdeb8a521663d1126f59bd9b9f5cd89c283aea486d504d83cc3434e81
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b68b6def98115c29639bfbb9892dc685e16dd40d3a7f21d7989118d9f43f7893a6d39dae80b9cc5a16ea7f471d359411a319a04e199c24657c5e2c70bcb908e9
|
7
|
+
data.tar.gz: 919ca1448fe8fa1ca53737f8f0fba3d81bca7740c55b7e05c9c6fd3d8eafec03e845d5eb420eb8e3cc7513f346019f40c0251171a29b35e81482b1b848355725
|
data/Gemfile
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
aws-sesocio-secrets (0.1.
|
4
|
+
aws-sesocio-secrets (0.1.14)
|
5
5
|
aws-sdk
|
6
6
|
|
7
7
|
GEM
|
@@ -29,13 +29,13 @@ GEM
|
|
29
29
|
aws-sdk-amplifybackend (1.7.0)
|
30
30
|
aws-sdk-core (~> 3, >= 3.119.0)
|
31
31
|
aws-sigv4 (~> 1.1)
|
32
|
-
aws-sdk-apigateway (1.
|
32
|
+
aws-sdk-apigateway (1.65.0)
|
33
33
|
aws-sdk-core (~> 3, >= 3.119.0)
|
34
34
|
aws-sigv4 (~> 1.1)
|
35
35
|
aws-sdk-apigatewaymanagementapi (1.23.0)
|
36
36
|
aws-sdk-core (~> 3, >= 3.119.0)
|
37
37
|
aws-sigv4 (~> 1.1)
|
38
|
-
aws-sdk-apigatewayv2 (1.
|
38
|
+
aws-sdk-apigatewayv2 (1.35.0)
|
39
39
|
aws-sdk-core (~> 3, >= 3.119.0)
|
40
40
|
aws-sigv4 (~> 1.1)
|
41
41
|
aws-sdk-appconfig (1.16.0)
|
@@ -217,7 +217,7 @@ GEM
|
|
217
217
|
aws-sdk-costexplorer (1.64.0)
|
218
218
|
aws-sdk-core (~> 3, >= 3.119.0)
|
219
219
|
aws-sigv4 (~> 1.1)
|
220
|
-
aws-sdk-customerprofiles (1.
|
220
|
+
aws-sdk-customerprofiles (1.10.0)
|
221
221
|
aws-sdk-core (~> 3, >= 3.119.0)
|
222
222
|
aws-sigv4 (~> 1.1)
|
223
223
|
aws-sdk-databasemigrationservice (1.56.0)
|
@@ -286,7 +286,7 @@ GEM
|
|
286
286
|
aws-sdk-eks (1.60.0)
|
287
287
|
aws-sdk-core (~> 3, >= 3.119.0)
|
288
288
|
aws-sigv4 (~> 1.1)
|
289
|
-
aws-sdk-elasticache (1.
|
289
|
+
aws-sdk-elasticache (1.60.0)
|
290
290
|
aws-sdk-core (~> 3, >= 3.119.0)
|
291
291
|
aws-sigv4 (~> 1.1)
|
292
292
|
aws-sdk-elasticbeanstalk (1.44.0)
|
@@ -307,7 +307,7 @@ GEM
|
|
307
307
|
aws-sdk-elastictranscoder (1.31.0)
|
308
308
|
aws-sdk-core (~> 3, >= 3.119.0)
|
309
309
|
aws-sigv4 (~> 1.1)
|
310
|
-
aws-sdk-emr (1.
|
310
|
+
aws-sdk-emr (1.49.0)
|
311
311
|
aws-sdk-core (~> 3, >= 3.119.0)
|
312
312
|
aws-sigv4 (~> 1.1)
|
313
313
|
aws-sdk-emrcontainers (1.6.0)
|
@@ -355,7 +355,7 @@ GEM
|
|
355
355
|
aws-sdk-glue (1.93.0)
|
356
356
|
aws-sdk-core (~> 3, >= 3.119.0)
|
357
357
|
aws-sigv4 (~> 1.1)
|
358
|
-
aws-sdk-gluedatabrew (1.
|
358
|
+
aws-sdk-gluedatabrew (1.12.0)
|
359
359
|
aws-sdk-core (~> 3, >= 3.119.0)
|
360
360
|
aws-sigv4 (~> 1.1)
|
361
361
|
aws-sdk-greengrass (1.42.0)
|
@@ -472,7 +472,7 @@ GEM
|
|
472
472
|
aws-sdk-lakeformation (1.16.0)
|
473
473
|
aws-sdk-core (~> 3, >= 3.119.0)
|
474
474
|
aws-sigv4 (~> 1.1)
|
475
|
-
aws-sdk-lambda (1.
|
475
|
+
aws-sdk-lambda (1.67.0)
|
476
476
|
aws-sdk-core (~> 3, >= 3.119.0)
|
477
477
|
aws-sigv4 (~> 1.1)
|
478
478
|
aws-sdk-lambdapreview (1.28.0)
|
@@ -640,7 +640,7 @@ GEM
|
|
640
640
|
aws-sdk-qldbsession (1.15.0)
|
641
641
|
aws-sdk-core (~> 3, >= 3.119.0)
|
642
642
|
aws-sigv4 (~> 1.1)
|
643
|
-
aws-sdk-quicksight (1.
|
643
|
+
aws-sdk-quicksight (1.51.0)
|
644
644
|
aws-sdk-core (~> 3, >= 3.119.0)
|
645
645
|
aws-sigv4 (~> 1.1)
|
646
646
|
aws-sdk-ram (1.28.0)
|
@@ -975,7 +975,7 @@ GEM
|
|
975
975
|
aws-sdk-s3outposts (1.5.0)
|
976
976
|
aws-sdk-core (~> 3, >= 3.119.0)
|
977
977
|
aws-sigv4 (~> 1.1)
|
978
|
-
aws-sdk-sagemaker (1.
|
978
|
+
aws-sdk-sagemaker (1.96.0)
|
979
979
|
aws-sdk-core (~> 3, >= 3.119.0)
|
980
980
|
aws-sigv4 (~> 1.1)
|
981
981
|
aws-sdk-sagemakeredgemanager (1.4.0)
|
@@ -1146,6 +1146,7 @@ PLATFORMS
|
|
1146
1146
|
x86_64-linux
|
1147
1147
|
|
1148
1148
|
DEPENDENCIES
|
1149
|
+
aws-sdk
|
1149
1150
|
aws-sdk-secretsmanager
|
1150
1151
|
aws-sesocio-secrets!
|
1151
1152
|
rake (~> 13.0)
|
data/lib/aws/sesocio/secrets.rb
CHANGED
@@ -17,19 +17,17 @@ module Aws
|
|
17
17
|
yield self
|
18
18
|
end
|
19
19
|
|
20
|
-
def self.get_parameters
|
21
|
-
response = JSON.parse(
|
22
|
-
response
|
23
|
-
|
24
|
-
ENV[key] = value
|
25
|
-
end
|
20
|
+
def self.get_parameters(repo)
|
21
|
+
response = JSON.parse(Aws::SSM::Client.new.get_parameter(name: "#{environment}-#{repo}").to_json)
|
22
|
+
response.each do |key, value|
|
23
|
+
ENV[key] = value
|
26
24
|
end
|
27
25
|
rescue
|
28
26
|
"Permission problem: che the configuration before continue."
|
29
27
|
end
|
30
28
|
|
31
|
-
def self.get_secrets
|
32
|
-
secret_name = "#{self.environment}-#{
|
29
|
+
def self.get_secrets(repo)
|
30
|
+
secret_name = "#{self.environment}-#{repo}-secret"
|
33
31
|
region_name = "us-east-1"
|
34
32
|
client = Aws::SecretsManager::Client.new(region: region_name)
|
35
33
|
begin
|
@@ -57,8 +55,10 @@ module Aws
|
|
57
55
|
end
|
58
56
|
|
59
57
|
def self.populate_env
|
60
|
-
|
61
|
-
|
58
|
+
self.repo_name.each do |repo|
|
59
|
+
get_parameters(repo)
|
60
|
+
get_secrets(repo)
|
61
|
+
end
|
62
62
|
end
|
63
63
|
end
|
64
64
|
end
|
data/lib/aws/sesocio/version.rb
CHANGED