diff --git a/README.md b/README.md index 702ce02..3f049be 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ with only SSH! * Linux kernel: overlayfs and tmpfs support * systemd * squashfs-tools - * wget + * curl ## Usage diff --git a/menhera.sh b/menhera.sh index 047dfce..a9a8fe5 100755 --- a/menhera.sh +++ b/menhera.sh @@ -24,7 +24,7 @@ confirm() { } get_rootfs() { - if [ -z ${ROOTFS+x} ]; then + if [ -n ${ROOTFS} ]; then echo "Getting rootfs URL..." ROOTFS_TIME=$(curl "https://uk.images.linuxcontainers.org/images/debian/stretch/amd64/default/?C=M;O=D" | grep "folder.gif" | head -n 1 | cut -d'>' -f7 | cut -d'/' -f1) ROOTFS="https://images.linuxcontainers.org/images/debian/stretch/amd64/default/${ROOTFS_TIME}/rootfs.squashfs" @@ -59,7 +59,7 @@ prepare_environment() { mkdir -p "${WORKDIR}/overlayfs_workdir" echo "Downloading temporary rootfs..." - wget -c "${ROOTFS}" -O "${WORKDIR}/rootfs.squashfs" + curl -LC -o "${WORKDIR}/rootfs.squashfs" - "${ROOTFS}" } mount_new_rootfs() {