uc3-sam-sceptre 0.0.24 → 0.0.25
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/uc3-sam-sceptre/version.rb +1 -1
- data/lib/uc3-sam-sceptre.rb +17 -6
- 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: 32b327c9a7d6940d11f3de18f55e1ae6c61507b09f66eb4f27113f2fd6667a8f
|
4
|
+
data.tar.gz: b90be4b3fa2d7734a7fd22dd8e28953c54c32f157b018044c98e0b0d14b0c6d3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b6075ea1fdf2c3d7926de9e1724260b7eb28399ad8f0f66f960f78a7ce9125db974853ce30c75d9c45777f74bf8c2d6f608250d1b9601b356f9e8f346ca0b575
|
7
|
+
data.tar.gz: 3c4226af364977c5de5bb4c8b079547bddf9914dbad03dc0ac991a4adb7b6db277e1d7ebc23f73add5caeafc73f2b39456ab8a94ae5eb908f1574c4968c53085
|
data/lib/uc3-sam-sceptre.rb
CHANGED
@@ -66,12 +66,8 @@ module Uc3SamSceptre
|
|
66
66
|
|
67
67
|
# Run a SAM deploy
|
68
68
|
def deploy(guided: false)
|
69
|
-
args =
|
70
|
-
|
71
|
-
"--confirm-changeset #{!@auto}",
|
72
|
-
'--capabilities CAPABILITY_NAMED_IAM',
|
73
|
-
'--disable-rollback false'
|
74
|
-
]
|
69
|
+
args = _base_args
|
70
|
+
|
75
71
|
# Add the S3 or ECR details depending on what we're working with
|
76
72
|
args << "--s3-bucket #{_locate_value(key: @s3_arn_key)&.gsub('arn:aws:s3:::', '')}" unless @s3_arn_key.nil?
|
77
73
|
args << "--s3-prefix #{@stack_name}" unless @s3_arn_key.nil?
|
@@ -83,8 +79,23 @@ module Uc3SamSceptre
|
|
83
79
|
system "sam deploy #{args.join(' ')}"
|
84
80
|
end
|
85
81
|
|
82
|
+
# Run a SAM delete
|
83
|
+
def delete
|
84
|
+
args = _base_args
|
85
|
+
system "sam delete #{args.join(' ')}"
|
86
|
+
end
|
87
|
+
|
86
88
|
private
|
87
89
|
|
90
|
+
def _base_args
|
91
|
+
[
|
92
|
+
"--stack-name #{@stack_name}",
|
93
|
+
"--confirm-changeset #{!@auto}",
|
94
|
+
'--capabilities CAPABILITY_NAMED_IAM',
|
95
|
+
'--disable-rollback false'
|
96
|
+
]
|
97
|
+
end
|
98
|
+
|
88
99
|
# Construct the AWS tags that SAM will use when building resources
|
89
100
|
def _sam_tags(admin_email: nil)
|
90
101
|
tags = [
|