Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions pkg/v1/remote/pusher.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,20 @@ func (p *Pusher) writer(ctx context.Context, repo name.Repository, o *options) (
return rw, rw.init(ctx)
}

func (p *Pusher) Put(ctx context.Context, ref name.Reference, t Taggable) error {
w, err := p.writer(ctx, ref.Context(), p.o)
if err != nil {
return err
}

m, err := taggableToManifest(t)
if err != nil {
return err
}

return w.commitManifest(ctx, ref, m)
}

func (p *Pusher) Push(ctx context.Context, ref name.Reference, t Taggable) error {
w, err := p.writer(ctx, ref.Context(), p.o)
if err != nil {
Expand Down
2 changes: 1 addition & 1 deletion pkg/v1/remote/write.go
Original file line number Diff line number Diff line change
Expand Up @@ -709,5 +709,5 @@ func Put(ref name.Reference, t Taggable, options ...Option) error {
if err != nil {
return err
}
return newPusher(o).Push(o.context, ref, t)
return newPusher(o).Put(o.context, ref, t)
}