1
0
mirror of https://github.com/ko-build/ko.git synced 2025-11-06 09:19:12 +02:00

Revive progress and warning logs (#203)

These got dropped when we pulled in:
https://github.com/google/go-containerregistry/pull/481

Which doesn't log by default, and requires opting in.
This commit is contained in:
jonjohnsonjr
2020-09-25 11:50:20 -07:00
committed by GitHub
parent d48767339f
commit 4a4d1b02bd
2 changed files with 7 additions and 1 deletions

View File

@@ -52,13 +52,14 @@ func getBaseImage(platform string) build.GetBase {
}
return func(s string) (build.Result, error) {
s = strings.TrimPrefix(s, build.StrictScheme)
// Viper configuration file keys are case insensitive, and are
// returned as all lowercase. This means that import paths with
// uppercase must be normalized for matching here, e.g.
// github.com/GoogleCloudPlatform/foo/cmd/bar
// comes through as:
// github.com/googlecloudplatform/foo/cmd/bar
ref, ok := baseImageOverrides[strings.ToLower(strings.TrimPrefix(s, build.StrictScheme))]
ref, ok := baseImageOverrides[strings.ToLower(s)]
if !ok {
ref = defaultBaseImage
}