dozzie / yumbootstrap

Linux chroot installer for Yum-based distributions
http://dozzie.jarowit.net/trac/wiki/yumbootstrap
GNU General Public License v3.0
119 stars 45 forks source link

Stream Output #3

Closed kellerkind closed 10 years ago

kellerkind commented 10 years ago

Can you make yumbootstrap output optional compatible with tars input stream format? This would be great to create yum based docker images in a single step.

$ yumbootstrap --verbose --tar-stream centos-6 - | docker import - <image_name>
dozzie commented 10 years ago

I like the idea, but given the circumstances, I don't quite see much gain.

Yum needs to run post-install scripts. It can't just directly produce tar archive and a temporary directory would be necessary. It would save a command like this:

(TMP=`mktemp -d`; yumbootstrap --verbose centos-6 $TMP && tar cf - -C $TMP .; rm -rf $TMP) | docker import - <image_name>