mirror of
https://github.com/ko-build/ko.git
synced 2025-01-05 14:50:50 +02:00
Fix the other publishers (#165)
This commit is contained in:
parent
ea2beac575
commit
ab4ca8ec17
@ -22,6 +22,7 @@ import (
|
||||
"github.com/google/go-containerregistry/pkg/name"
|
||||
v1 "github.com/google/go-containerregistry/pkg/v1"
|
||||
"github.com/google/go-containerregistry/pkg/v1/daemon"
|
||||
"github.com/google/ko/pkg/build"
|
||||
)
|
||||
|
||||
const (
|
||||
@ -42,6 +43,7 @@ func NewDaemon(namer Namer, tags []string) Interface {
|
||||
|
||||
// Publish implements publish.Interface
|
||||
func (d *demon) Publish(img v1.Image, s string) (name.Reference, error) {
|
||||
s = strings.TrimPrefix(s, build.StrictScheme)
|
||||
// https://github.com/google/go-containerregistry/issues/212
|
||||
s = strings.ToLower(s)
|
||||
|
||||
|
@ -22,6 +22,7 @@ import (
|
||||
"github.com/google/go-containerregistry/pkg/name"
|
||||
v1 "github.com/google/go-containerregistry/pkg/v1"
|
||||
"github.com/google/go-containerregistry/pkg/v1/tarball"
|
||||
"github.com/google/ko/pkg/build"
|
||||
)
|
||||
|
||||
type TarballPublisher struct {
|
||||
@ -45,6 +46,7 @@ func NewTarball(file, base string, namer Namer, tags []string) *TarballPublisher
|
||||
|
||||
// Publish implements publish.Interface.
|
||||
func (t *TarballPublisher) Publish(img v1.Image, s string) (name.Reference, error) {
|
||||
s = strings.TrimPrefix(s, build.StrictScheme)
|
||||
// https://github.com/google/go-containerregistry/issues/212
|
||||
s = strings.ToLower(s)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user