Skip to content

Commit

Permalink
Revert "drop gzip support when compressing base.tar file. Always use …
Browse files Browse the repository at this point in the history
…xz."

This reverts commit a419535.
  • Loading branch information
Thomas Lange committed Apr 2, 2015
1 parent 2fa727f commit 953cf1b
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
17 changes: 15 additions & 2 deletions bin/fai-make-nfsroot
Expand Up @@ -156,6 +156,11 @@ deldir=$NFSROOT
ROOTCMD="chroot $NFSROOT"
export DEBIAN_FRONTEND=noninteractive

usexz=0
if [ -x "$(which xz)" ]; then
usexz=1
fi

# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
adjust_nfsroot() {

Expand Down Expand Up @@ -290,9 +295,17 @@ create_base() {
call_debootstrap $FAI_DEBOOTSTRAP
$ROOTCMD apt-get clean
rm -f $NFSROOT/etc/resolv.conf $NFSROOT/etc/hostname $NFSROOT/etc/udev/rules.d/70-persistent-net.rules
echo "Creating base.tar.xz"
if [ $usexz -eq 0 ]; then
echo "Creating base.tar.gz"
else
echo "Creating base.tar.xz"
fi
tar --one-file-system -C $NFSROOT -cf $NFSROOT/var/tmp/base.tar --exclude var/tmp/base.tar --exclude 'var/lib/apt/lists/*_*' .
nice xz -q $NFSROOT/var/tmp/base.tar &
if [ $usexz -eq 1 ]; then
nice xz -q $NFSROOT/var/tmp/base.tar &
else
nice gzip $NFSROOT/var/tmp/base.tar &
fi
}
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
extract_base() {
Expand Down
2 changes: 1 addition & 1 deletion debian/control
Expand Up @@ -39,7 +39,7 @@ Description: Documentation for FAI

Package: fai-server
Architecture: all
Depends: fai-client, debootstrap, xz-utils, ${misc:Depends}
Depends: fai-client, debootstrap, ${misc:Depends}
Recommends: nfs-kernel-server, isc-dhcp-server, tftpd-hpa | atftpd, openssh-server, openssh-client, openbsd-inetd | inet-superserver, libproc-daemon-perl
Suggests: debmirror, reprepro, xorriso, binutils, grub, aptitude, perl-tk
Description: Fully Automatic Installation server package
Expand Down

0 comments on commit 953cf1b

Please sign in to comment.