-
Notifications
You must be signed in to change notification settings - Fork 538
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 append-file(s) command to crane #932
Comments
I also recently found myself wanting something like this 😄 As a workaround, you can pipe tar's output to crane's stdin:
The @jonjohnsonjr wdyt? |
I believe you want something like this:
Tar has flags for Modifying File and Member Names that can help reposition things within the archive, if it needs to go in a particular place, see If that doesn't hit your use-case, let me know. I'm sure we can figure something out.
I am wary of doing this because we're going to end up inventing a non-standard syntax for something that tar already does. We could implement a very small subset of tar's functionality (if you just care about the filename), but if we do this, people will ask about how to change permissions and stuff, and I'd rather not bake that into a command that also appends things. I think we are missing some functionality in
Process substitution is a nice alternative to that. |
See #934 |
Yeah I thought about using tar, but the problem is that GNU tar and whatever you get on macOS are quite different, so it would be nice if I didn't have to rely on specific OS tooling. |
Ah, sorry, I am unfortunately ignorant here as I only have linux devices currently. What kinds of differences are there, and can we paper over them without the abstraction being too leaky? Does windows also suffer from this? One thing that has me worried is docker's package for this: https://github.com/moby/moby/tree/d5209b29b9777e0b9713d87847a5dc8ce9d93da6/pkg/archive There seems to be a lot of platform-specific stuff, and I'd like to avoid re-implementing all of that or even just importing it because the dependency graph in docker/docker can be pretty scary. One thing that feels kind of interesting to me would be exposing something like
Maybe we could compose this with #934 If we wanted multi-file archives maybe we could do something very silly like:
... which would upload a gzipped tarball to Tarring up a whole directory seems like a whole different beast, and I'm not sure if that's going to be any easier than just working around the differences in
🤷 |
This issue is stale because it has been open for 90 days with no |
It would be useful if we could have a command that could do something like:
Or imitate ko by doing:
And end up with a container image that contains the app binary at
/usr/bin/app
.Basically roll some basic tarring functions into crane itself
The text was updated successfully, but these errors were encountered: