tools: Add a mkimage variant to build a non-bootable ISO.

Signed-off-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
This commit is contained in:
Rolf Neugebauer
2018-07-24 16:47:16 +01:00
parent 66b7417819
commit 594ce1251d
3 changed files with 36 additions and 0 deletions

18
tools/mkimage-iso/make-iso Executable file
View File

@@ -0,0 +1,18 @@
#!/bin/sh
set -e
mkdir -p /tmp/iso
cd /tmp/iso
# input is a tarball of filesystem on stdin
# output is an iso on stdout
# extract. BSD tar auto recognises compression, unlike GNU tar
# only if stdin is a tty, if so need files volume mounted...
[ -t 0 ] || bsdtar xzf -
genisoimage -o ../linuxkit.iso -l -J -R \
-joliet-long -input-charset utf8 \
-V LinuxKit .
cat ../linuxkit.iso