Use base64 strings for chart repo certs [#74]

This should be a more flexible option since certificates aren't likely
to be part of the actual workspace and may be environment-dependent. It
also mirrors the kube_certificate, which is nice.
This commit is contained in:
Erin Call
2020-01-20 15:40:36 -08:00
parent ee6d8d1724
commit 18313eeb5c
8 changed files with 181 additions and 18 deletions

View File

@@ -64,6 +64,7 @@ func (suite *UpgradeTestSuite) TestNewUpgrade() {
suite.Equal(true, up.atomic)
suite.Equal(true, up.cleanupOnFail)
suite.NotNil(up.config)
suite.NotNil(up.certs)
}
func (suite *UpgradeTestSuite) TestPrepareAndExecute() {
@@ -136,9 +137,10 @@ func (suite *UpgradeTestSuite) TestPrepareWithUpgradeFlags() {
Force: true,
AtomicUpgrade: true,
CleanupOnFail: true,
RepoCAFile: "local_ca.cert",
}
u := NewUpgrade(cfg)
// inject a ca cert filename so repoCerts won't create any files that we'd have to clean up
u.certs.caCertFilename = "local_ca.cert"
command = func(path string, args ...string) cmd {
suite.Equal(helmBin, path)