@@ -11,9 +11,9 @@ import (
11
11
"github.com/pkg/errors"
12
12
)
13
13
14
- type parameterOperation func (bndl * bundle.Bundle , params map [string ]string ) error
14
+ type mergeBundleOpt func (bndl * bundle.Bundle , params map [string ]string ) error
15
15
16
- func withFileParameters (parametersFiles []string ) parameterOperation {
16
+ func withFileParameters (parametersFiles []string ) mergeBundleOpt {
17
17
return func (bndl * bundle.Bundle , params map [string ]string ) error {
18
18
p , err := parameters .LoadFiles (parametersFiles )
19
19
if err != nil {
@@ -26,7 +26,7 @@ func withFileParameters(parametersFiles []string) parameterOperation {
26
26
}
27
27
}
28
28
29
- func withCommandLineParameters (overrides []string ) parameterOperation {
29
+ func withCommandLineParameters (overrides []string ) mergeBundleOpt {
30
30
return func (bndl * bundle.Bundle , params map [string ]string ) error {
31
31
d := cliopts .ConvertKVStringsToMap (overrides )
32
32
for k , v := range d {
@@ -36,7 +36,7 @@ func withCommandLineParameters(overrides []string) parameterOperation {
36
36
}
37
37
}
38
38
39
- func withSendRegistryAuth (sendRegistryAuth bool ) parameterOperation {
39
+ func withSendRegistryAuth (sendRegistryAuth bool ) mergeBundleOpt {
40
40
return func (bndl * bundle.Bundle , params map [string ]string ) error {
41
41
if _ , ok := bndl .Parameters [internal .ParameterShareRegistryCredsName ]; ok {
42
42
val := "false"
@@ -49,7 +49,7 @@ func withSendRegistryAuth(sendRegistryAuth bool) parameterOperation {
49
49
}
50
50
}
51
51
52
- func withOrchestratorParameters (orchestrator string , kubeNamespace string ) parameterOperation {
52
+ func withOrchestratorParameters (orchestrator string , kubeNamespace string ) mergeBundleOpt {
53
53
return func (bndl * bundle.Bundle , params map [string ]string ) error {
54
54
if _ , ok := bndl .Parameters [internal .ParameterOrchestratorName ]; ok {
55
55
params [internal .ParameterOrchestratorName ] = orchestrator
@@ -61,7 +61,7 @@ func withOrchestratorParameters(orchestrator string, kubeNamespace string) param
61
61
}
62
62
}
63
63
64
- func mergeBundleParameters (c * claim.Claim , ops ... parameterOperation ) error {
64
+ func mergeBundleParameters (c * claim.Claim , ops ... mergeBundleOpt ) error {
65
65
bndl := c .Bundle
66
66
if c .Parameters == nil {
67
67
c .Parameters = make (map [string ]interface {})
0 commit comments