29 lines
717 B
Go
29 lines
717 B
Go
package helmhelper
|
|
|
|
import (
|
|
"git.badhouseplants.net/allanger/shoebill/pkg/repository"
|
|
)
|
|
|
|
const (
|
|
MOCK_LATEST_VERSION = "v1.12.1"
|
|
MOCK_CHART_PATH = ".charts/repo-release-latest/release-latest.gz"
|
|
)
|
|
|
|
type Mock struct{}
|
|
|
|
func NewHelmMock() Helmhelper {
|
|
return &Mock{}
|
|
}
|
|
|
|
func (h *Mock) FindLatestVersion(dir, chart string, repository repository.Repository) (version string, err error) {
|
|
return MOCK_LATEST_VERSION, nil
|
|
}
|
|
|
|
func (h *Mock) PullChart(workdirPath string, repository repository.Repository, chart, version string) (path string, err error) {
|
|
return MOCK_CHART_PATH, nil
|
|
}
|
|
|
|
func (h *Mock) RenderChart(workdirPath string, repository repository.Repository, ch2art, version string) error {
|
|
return nil
|
|
}
|