From 29bb770672b5220d9f363c7dd32aa045d59775f7 Mon Sep 17 00:00:00 2001 From: jalr Date: Fri, 21 Jun 2019 17:12:32 +0200 Subject: [PATCH] Revert "Replace aria2c with wget" This reverts commit 208b96d8b65de93370f2324792e9991e2d9ac191. --- packer/initramfs/labsync | 2 +- packer/initramfs/labsync-prereqs | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/packer/initramfs/labsync b/packer/initramfs/labsync index 2f707d0..d001a54 100755 --- a/packer/initramfs/labsync +++ b/packer/initramfs/labsync @@ -98,7 +98,7 @@ labsync_mount_root() { vg_name="vglab" if [ -z "$labsync_localboot" ]; then labsync_info "Downloading torrent file from ${labsync_torrent}" - while ! wget -O /tmp/torrent "${labsync_torrent}"; do sleep 1; done + while ! aria2c -t 10 --follow-torrent=false --dir /tmp -o torrent "${labsync_torrent}"; do sleep 1; done aria2c -S /tmp/torrent > /tmp/torrent_info squashfs_file="$(sed -n '/idx|path\/length/,${s/\s*1|\(.*\)$/\1/p}' /tmp/torrent_info)" image_size_bytes="$(sed -n 's/Total Length: .*(\([0-9,]*\)).*$/\1/p' /tmp/torrent_info | tr -d ',')" diff --git a/packer/initramfs/labsync-prereqs b/packer/initramfs/labsync-prereqs index f02a0ee..8345c6d 100755 --- a/packer/initramfs/labsync-prereqs +++ b/packer/initramfs/labsync-prereqs @@ -7,8 +7,6 @@ case $1 in ## . /usr/share/initramfs-tools/hook-functions rm -f "$DESTDIR/sbin/mke2fs" - mkdir -p "$DESTDIR/lib/x86_64-linux-gnu" - cp /lib/x86_64-linux-gnu/libnss_dns* "$DESTDIR/lib/x86_64-linux-gnu" copy_exec /sbin/e2fsck copy_exec /sbin/mke2fs copy_exec /sbin/sfdisk