diff --git a/pkg/curatedpackages/packagecontrollerclient.go b/pkg/curatedpackages/packagecontrollerclient.go index e0fb2d28832a..6d8e886ce7b6 100644 --- a/pkg/curatedpackages/packagecontrollerclient.go +++ b/pkg/curatedpackages/packagecontrollerclient.go @@ -34,8 +34,10 @@ import ( var secretsValueYaml string const ( - eksaDefaultRegion = "us-west-2" - valueFileName = "values.yaml" + eksaDefaultRegion = "us-west-2" + valueFileName = "values.yaml" + defaultRegistryMirrorUsername = "username" + defaultRegistryMirrorPassword = "password" ) type PackageControllerClientOpt func(client *PackageControllerClient) @@ -305,7 +307,7 @@ func (pc *PackageControllerClient) CreateHelmOverrideValuesYaml() (string, []byt func (pc *PackageControllerClient) generateHelmOverrideValues() ([]byte, error) { var err error - endpoint, username, password, caCertContent, insecureSkipVerify := "", "", "", "", "false" + endpoint, username, password, caCertContent, insecureSkipVerify := "", defaultRegistryMirrorUsername, defaultRegistryMirrorPassword, "", "false" if pc.registryMirror != nil { endpoint = pc.registryMirror.BaseRegistry if pc.registryMirror.Auth { diff --git a/pkg/curatedpackages/testdata/values_empty.yaml b/pkg/curatedpackages/testdata/values_empty.yaml index 0b869c7592a8..65970c5779da 100644 --- a/pkg/curatedpackages/testdata/values_empty.yaml +++ b/pkg/curatedpackages/testdata/values_empty.yaml @@ -1,7 +1,7 @@ registryMirrorSecret: endpoint: "" - username: "" - password: "" + username: "dXNlcm5hbWU=" + password: "cGFzc3dvcmQ=" cacertcontent: "" insecure: "ZmFsc2U=" awsSecret: diff --git a/pkg/curatedpackages/testdata/values_empty_registrymirrorsecret.yaml b/pkg/curatedpackages/testdata/values_empty_registrymirrorsecret.yaml index 0e7b260c6859..4c3038dcce45 100644 --- a/pkg/curatedpackages/testdata/values_empty_registrymirrorsecret.yaml +++ b/pkg/curatedpackages/testdata/values_empty_registrymirrorsecret.yaml @@ -1,7 +1,7 @@ registryMirrorSecret: endpoint: "" - username: "" - password: "" + username: "dXNlcm5hbWU=" + password: "cGFzc3dvcmQ=" cacertcontent: "" insecure: "ZmFsc2U=" awsSecret: