cfnpp 0.3.8 → 0.3.9
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/bin/cfnpp +16 -0
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c9bd603f0ebfc570a3f4ad43a03058ce19f8d550
|
|
4
|
+
data.tar.gz: 4f4d1ef02b710c3f8c75329d5cf21bd23da642f7
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 01849425f5ee63c3c5f9085656c1227809197db723b4cbd26a58d2a1426fe3983c9b1e8df2dfcd994bb7f5b3592bda94c5c10b369953ccbf04f745326c8790bb
|
|
7
|
+
data.tar.gz: 950c1d0b41bf1624e4c98ffacb56f7afcb40d015540772eb1170f44361f948e77d9f970a3a442e919e3f1914864e39248dde52e3cbf93c437674a3386a15b344
|
data/bin/cfnpp
CHANGED
|
@@ -99,6 +99,15 @@ eot
|
|
|
99
99
|
stack_name = "#{stack_type}--#{environment_name}--#{environment_type}"
|
|
100
100
|
conf_path = cli_opts[:confpath] || "#{basepath}/#{stack_type}/conf/#{environment_type}.yml"
|
|
101
101
|
|
|
102
|
+
# Support config overrides for specific environment names, if such a file exists.
|
|
103
|
+
conf_override_path = ''
|
|
104
|
+
unless cli_opts[:confpath]
|
|
105
|
+
conf_override_path = "#{basepath}/#{stack_type}/conf/#{environment_name}.yml"
|
|
106
|
+
if !File.file?(conf_override_path)
|
|
107
|
+
conf_override_path = ''
|
|
108
|
+
end
|
|
109
|
+
end
|
|
110
|
+
|
|
102
111
|
stack = cfn.stacks[stack_name]
|
|
103
112
|
if stack.exists?
|
|
104
113
|
status = stack.status
|
|
@@ -134,8 +143,15 @@ eot
|
|
|
134
143
|
exit 1
|
|
135
144
|
end
|
|
136
145
|
|
|
146
|
+
puts "loading config from (#{conf_path})"
|
|
137
147
|
conf_yaml = File.read(conf_path)
|
|
138
148
|
opts = YAML::load(conf_yaml)
|
|
149
|
+
if conf_override_path.size()
|
|
150
|
+
puts "applying overrides from (#{conf_override_path})"
|
|
151
|
+
conf_override_yaml = File.read(conf_override_path)
|
|
152
|
+
opts_override = YAML::load(conf_override_yaml)
|
|
153
|
+
opts.merge!(opts_override)
|
|
154
|
+
end
|
|
139
155
|
|
|
140
156
|
timestamp = Time.now.utc.strftime("%Y-%m-%dT%H.%M.%S.%LZ")
|
|
141
157
|
template_info = get_template_info()
|