dockviz icon indicating copy to clipboard operation
dockviz copied to clipboard

Create a more generic docker image

Open justone opened this issue 9 years ago • 5 comments
trafficstars

From @gesellix:

Hey, I made a combined image for personal use, but it might help you to build a more generic variant. I also stumbled over some dynamic library issues when running a dockviz release in an Alpine image (using musl libc instead of glibc), which is why I build the binary during the Docker build.

See https://github.com/gesellix/docker-tree-viz for the source.

justone avatar May 08 '16 19:05 justone

What would be needed in a more generic image?

justone avatar May 08 '16 19:05 justone

As you can see in https://github.com/gesellix/docker-tree-viz/blob/master/viz.sh I use some dirty script hacking to handle the different options dockviz supports. Apart from the knowledge the shell script needs about dockviz, the main issue from my perspective is that you cannot easily provide images via stdin anymore. Maybe it would be nice to add an option to dockviz which allowed to "post process" its result by calling another executable. That would minimize the need to wrap dockviz in a shell script. Such a feature should obviously be optional. Then, without the wrapper script, passing input via stdin would become easier again.

gesellix avatar May 08 '16 21:05 gesellix

I guess a first step to a more generic dockviz image would be to change the base image from scratch to something like alpine or similar. Alpine would be nice, because their package manager/repository already provides most utilities you and others might need, which consequently makes a dockviz image suitable as base image for more specific use cases.

gesellix avatar May 08 '16 21:05 gesellix

Makes sense. Thanks for explaining your use case.

I'll see what I can do.

justone avatar May 08 '16 21:05 justone

Though I'm no Golang expert, I'd be happy to help by providing PRs if you like :-)

gesellix avatar May 08 '16 21:05 gesellix