-
Notifications
You must be signed in to change notification settings - Fork 405
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add additional output formats (tarball and layout) #134
Conversation
MultiPublisher mimics io.MultiWriter in that it will publish an image to multiple publish.Interface implementations.
This adds support for publishing in the tarball format and to an OCI image layout. The tarball format isn't great, yet. It only supports writing once instead of appending.
These were spread all over the place for no reasons. Now all the publisher related options are grouped together.
Adds --oci-layout-path, --tarball, and --push flags. --push=false will disable the default behavior of publishing to a registry.
3fbf9ac
to
12df896
Compare
@bioball @josephlewis42 @jbarrick-mesosphere Would this work for all of your needs? |
Awesome!! Although, I just tried it, and it doesn't seem like all the images within $ ko resolve --tarball=output.tar -f config > release.yaml
$ cat output.tar | docker load
# => Loaded image: localhost:5000/mypipelineimages/controller-10a3e32792f33651396d02b6855a6e36:latest However, I'd expect to find a lot more images in there. These are the images that got built and inserted into
|
This allows us to defer writing to the tarball until we've collected all the images that have been published.
Ahh yeah I forgot to go back and fix this, thanks. There's not an easy way to append an image to a tarball right now (since the interface supports streaming writes). Hacked a workaround in to just buffer images until the end and write them out in a Close(). Try it now 😄 |
Looks like it works! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM for the tarball stuff
This looks like it will fit our purposes nicely! |
Fixes #128
Closes #95
This is staged in a few commits that should be easy to review independently: