From 6ce12bbdda72c647b6e8157d5c8544fb0423d754 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timoth=C3=A9e=20Floure?= Date: Wed, 22 Jan 2020 17:24:47 +0100 Subject: [PATCH] Ubuntu image: use configurable APT mirror, fix -y flag for rdnssd, output name --- ubuntu-unclound-image.sh | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/ubuntu-unclound-image.sh b/ubuntu-unclound-image.sh index ee113ea..61edc7c 100755 --- a/ubuntu-unclound-image.sh +++ b/ubuntu-unclound-image.sh @@ -11,9 +11,10 @@ set -x # XXX: Handle command-line arguments? RELEASE=eoan # 19.10 ARCH=amd64 -IMAGE_PATH=ubuntu-$RELEASE-$(date --iso-8601).img.qcow2 +IMAGE_PATH=ubuntu-uncloud-$RELEASE-$(date --iso-8601).img.qcow2 IMAGE_SIZE=10G NBD_DEVICE=/dev/nbd0 +APT_MIRROR=http://archive.ubuntu.com/ubuntu/ cleanup() { # The order here is important. @@ -73,7 +74,7 @@ mount "${NBD_DEVICE}p1" /mnt/boot debootstrap \ --arch=$ARCH $RELEASE \ - /mnt http://archive.ubuntu.com/ubuntu/ + /mnt "$APT_MIRROR" mount --bind /dev /mnt/dev mount --bind /dev/pts /mnt/dev/pts @@ -94,15 +95,15 @@ EOF # Configure package sources and update package index. cat >/mnt/etc/apt/sources.list <