minfra-cli 2.2.0 → 3.0.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: 20d6ef8704c3f8f61e70deebd60afc9663a9df46e2741f03a30eb9f5020fe2e0
4
- data.tar.gz: b173a73d17868a0b8f13ce11cdefc0e997aa50af7bb07c0448946fa121d9275d
3
+ metadata.gz: 6aee1958bcccfa6f91dc0d2b6e331478e9bb970353768a9d08083a982299c0d1
4
+ data.tar.gz: db65ab93061611f75d4cbe2016bf08800588cdbc3a1911aea60c498f2f15dc08
5
5
  SHA512:
6
- metadata.gz: 5725dd5eed53295676e895f14bf84a3d729fa82664b5578dde1540f47455b1050e236d9321291185ed935e14a1a9de3b691e82b8ce83db9c0f7b19419877cab4
7
- data.tar.gz: 6b92c6757e2d0ccfaefe8d6847c55c77800159e820ff7f41f54c4d3bff9801118b566febed21be9f92bcfd4cd9a443dcb29f09487e8a7366d0273a92858be337
6
+ metadata.gz: 3a1b7e97a137c63e79b336cd83d20eedc4dfec249f41b36e7627359d449eed8c1db3890f83190bccd84a8987fed5d5df889deb6938b50d7ec5ec4b24f1f295a5
7
+ data.tar.gz: 8e0c012fd0cf40cd33e7d3edf7dcad792705d4a3e9f26ba1244f13d41d76656ffed49497bb821367f32c8ede8dc57c24645a7f333c0522126079cd2c49541f13
data/CHANGELOG.md CHANGED
@@ -1,15 +1,21 @@
1
+ # 3.0.1
2
+ * fixing: dubblequotes in helm values should be escaped
3
+ # 3.0.0
4
+ * change: debug output on template errors
5
+ Incompatibility
6
+ * change: used_vars are turned into true yaml types when creating the value file
1
7
  # 2.2.0
2
8
  * fixing: should not modify l('env.roles')
3
9
  * cleanup: removing template testing --debug flag, causing noise
4
10
  * cleanup: removing Documentation hooks
5
11
  * fixing: hiera lookup retrying on gpg memory error exceptions
6
- *
12
+ * adding: gpgme dependency
7
13
  # 2.1.0
8
- * add :all hook
9
- * fixing setup dev
10
- * colored errors
11
- * wrapping hiera lookup errors of gpg
12
- * adding HIERA_DEBUG_LOOKUPS=true
14
+ * adding: :all hook
15
+ * fixing: setup dev
16
+ * adding: colored errors and warnings
17
+ * change: wrapping hiera lookup errors of gpg
18
+ * adding: HIERA_DEBUG_LOOKUPS=true
13
19
  # 2.0.1
14
20
  Refactorings
15
21
  * installing into Kernel only when 'exec' not at 'init' time
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Minfra
4
4
  module Cli
5
- VERSION = '2.2.0'
5
+ VERSION = '3.0.1'
6
6
  end
7
7
  end
@@ -196,6 +196,7 @@ module Orchparty
196
196
 
197
197
  debug('Helm: template check: OK')
198
198
  else
199
+ system("#{cmd} --debug")
199
200
  error('Helm: template check: FAIL')
200
201
  end
201
202
  end
@@ -246,7 +247,20 @@ module Orchparty
246
247
  output_chart_path: output_chart_path
247
248
  )
248
249
  used_vars.each do |variable, value|
249
- helm_values.puts "#{variable}: \"#{value}\""
250
+ value = value.gsub('"','\"') if value.is_a?(String)
251
+ if value.is_a?(Numeric) && value >= 1000000 # this is bad as conversion is done only in some cases
252
+ value = value.to_s # see https://github.com/helm/helm/issues/3001
253
+ end
254
+ yml = { variable => value}.to_yaml[4..-1]
255
+ yml = case
256
+ when yml.match(/!ruby\/object/)
257
+ { variable => value.to_s}.to_yaml[4..-1]
258
+ when yml.match(/!ruby\/array:Hashie::Array/)
259
+ { variable => value.to_a}.to_yaml[4..-1]
260
+ else
261
+ yml
262
+ end
263
+ helm_values.write(yml)
250
264
  end
251
265
  end
252
266
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: minfra-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.0
4
+ version: 3.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Schrammel
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-02-02 00:00:00.000000000 Z
11
+ date: 2024-03-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor