helm-wrapper 1.4.0 → 1.6.2
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/lib/helm-wrapper/shared/auths/azure.rb +1 -1
- data/lib/helm-wrapper/shared/variables.rb +12 -9
- data/lib/helm-wrapper/version.rb +1 -1
- data/lib/helm-wrapper.rb +2 -2
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d0c6825235f55e18927bc81c56ee25b1a2da087cb13abc76c331b262a21e4948
|
|
4
|
+
data.tar.gz: c884c4abc0009521dfdc11d5a8a4c71e8839a45012a0165d6dcdeceb31314601
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 20da545ab1511ef1220b31d21aeca1b35f0f0967dbd96dfb8086d023f372960b6f135c6203c2e500a92989e2e802110864be49dc4643684f36cab278583b1b02
|
|
7
|
+
data.tar.gz: ce9bd34edf9c901d5e711e67ce6002acd0d70f03d3dbcb6b94b30f971721bf3592cede7595df3eefb6f0b6c235bae707e5a7b72bc6460bb9cf7aab84c4eb2204
|
|
@@ -92,7 +92,7 @@ module HelmWrapper
|
|
|
92
92
|
###############################################################################
|
|
93
93
|
|
|
94
94
|
def cli()
|
|
95
|
-
output = logger.colour ? "
|
|
95
|
+
output = logger.colour ? "yamlc" : "yaml"
|
|
96
96
|
cmdline = "\"#{@@az}\" version --output \"#{output}\""
|
|
97
97
|
return(system(cmdline) || false)
|
|
98
98
|
end
|
|
@@ -37,7 +37,7 @@ module HelmWrapper
|
|
|
37
37
|
core[:namespace] = nil
|
|
38
38
|
core[:release] = release
|
|
39
39
|
|
|
40
|
-
user = cleanse(variables: identifiers, reserved: core.keys)
|
|
40
|
+
user = cleanse(variables: identifiers, reserved: core.keys, downcase: true)
|
|
41
41
|
|
|
42
42
|
begin
|
|
43
43
|
core[:namespace] = namespace % user
|
|
@@ -49,7 +49,7 @@ module HelmWrapper
|
|
|
49
49
|
|
|
50
50
|
@core = core
|
|
51
51
|
@identifiers = sort ? merged.sort.to_h : merged
|
|
52
|
-
@values =
|
|
52
|
+
@values = Hash.new
|
|
53
53
|
@files = Array.new
|
|
54
54
|
end
|
|
55
55
|
|
|
@@ -98,7 +98,7 @@ module HelmWrapper
|
|
|
98
98
|
###############################################################################
|
|
99
99
|
|
|
100
100
|
def clear_variables()
|
|
101
|
-
@values =
|
|
101
|
+
@values = Hash.new
|
|
102
102
|
end
|
|
103
103
|
|
|
104
104
|
###############################################################################
|
|
@@ -107,17 +107,20 @@ module HelmWrapper
|
|
|
107
107
|
|
|
108
108
|
###############################################################################
|
|
109
109
|
|
|
110
|
-
def cleanse(variables:, reserved:)
|
|
110
|
+
def cleanse(variables:, reserved:, downcase: false)
|
|
111
111
|
result = Hash.new
|
|
112
112
|
|
|
113
113
|
variables.keys.each do |key|
|
|
114
114
|
logger.fatal("Could not clean variables hash. All keys MUST be strings!") unless key.kind_of?(String)
|
|
115
|
-
logger.fatal("Could not clean variables hash, key: #{key.downcase} is reserved or already in use and cannot be used!") if reserved.include?(key.downcase.to_sym)
|
|
116
|
-
logger.fatal("Could not clean variables hash, duplicate key found: #{key.downcase}!") if result.key?(key.downcase.to_sym)
|
|
117
|
-
logger.fatal("Could not clean variables hash, value for: #{key.downcase} is not a string!") unless variables[key].kind_of?(String)
|
|
118
|
-
logger.fatal("Could not clean variables hash, value for: #{key.downcase} is empty!") if variables[key].strip.empty?
|
|
119
115
|
|
|
120
|
-
|
|
116
|
+
sym = downcase ? key.downcase.to_sym : key.to_sym
|
|
117
|
+
|
|
118
|
+
logger.fatal("Could not clean variables hash, key: #{sym.to_s} is reserved or already in use and cannot be used!") if reserved.include?(sym)
|
|
119
|
+
logger.fatal("Could not clean variables hash, duplicate key found: #{sym.to_s}!") if result.key?(sym)
|
|
120
|
+
logger.fatal("Could not clean variables hash, value for: #{sym.to_s} is not a string!") unless variables[key].kind_of?(String)
|
|
121
|
+
logger.fatal("Could not clean variables hash, value for: #{sym.to_s} is empty!") if variables[key].strip.empty?
|
|
122
|
+
|
|
123
|
+
result[sym] = variables[key].strip
|
|
121
124
|
end
|
|
122
125
|
|
|
123
126
|
return result
|
data/lib/helm-wrapper/version.rb
CHANGED
data/lib/helm-wrapper.rb
CHANGED
|
@@ -60,7 +60,7 @@ module HelmWrapper
|
|
|
60
60
|
|
|
61
61
|
###############################################################################
|
|
62
62
|
|
|
63
|
-
def self.development_tasks(chart:, path:, options: Hash.new)
|
|
63
|
+
def self.development_tasks(chart:, path:, oci: false, options: Hash.new)
|
|
64
64
|
@logger.info("Building development tasks for path: #{path}...")
|
|
65
65
|
|
|
66
66
|
@logger.fatal("Options must be specified as a hash!") unless options.kind_of?(Hash)
|
|
@@ -80,7 +80,7 @@ module HelmWrapper
|
|
|
80
80
|
|
|
81
81
|
tasks = Array.new
|
|
82
82
|
tasks << HelmWrapper::Tasks::Binary.new(binary: binary)
|
|
83
|
-
tasks << HelmWrapper::Tasks::Push.new(binary: binary, chart: chart)
|
|
83
|
+
tasks << HelmWrapper::Tasks::Push.new(binary: binary, chart: chart) if oci
|
|
84
84
|
tasks << HelmWrapper::Tasks::Validate.new(binary: binary, chart: chart)
|
|
85
85
|
return tasks
|
|
86
86
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: helm-wrapper
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.6.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Richard Lees
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: exe
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2021-
|
|
11
|
+
date: 2021-08-24 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rake
|
|
@@ -83,7 +83,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
83
83
|
- !ruby/object:Gem::Version
|
|
84
84
|
version: '0'
|
|
85
85
|
requirements: []
|
|
86
|
-
rubygems_version: 3.2.
|
|
86
|
+
rubygems_version: 3.2.22
|
|
87
87
|
signing_key:
|
|
88
88
|
specification_version: 4
|
|
89
89
|
summary: A ruby wrapper for managing Helm binaries and chart deployment.
|