From c184977a90ff187acd4e3f18fff4ae5d853b5852 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20=27sil2100=27=20Zemczak?= Date: Wed, 3 Oct 2018 11:51:49 +0200 Subject: [PATCH 1/4] Decide what model assertion series to fetch depending on the suite. For xenial use 16 and for others (so bionic+): 18. --- live-build/auto/config | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/live-build/auto/config b/live-build/auto/config index 5ab67fac..7cfd4c17 100755 --- a/live-build/auto/config +++ b/live-build/auto/config @@ -185,11 +185,17 @@ case $IMAGEFORMAT in *) UBUNTU_IMAGE_ARGS="" ;; esac + case $SUITE in + xenial) + CORE_SERIES=16 ;; + *) + CORE_SERIES=18 ;; + esac echo "IMAGEFORMAT=$IMAGEFORMAT" >> config/common echo "UBUNTU_IMAGE_ARGS=\"$UBUNTU_IMAGE_ARGS\"" >> config/common # Store model assertion in top dir to get it picked up later as a build artifact - env SNAPPY_STORE_NO_CDN=1 snap known --remote model series=16 model="$MODEL" brand-id=canonical > "$PREFIX".model-assertion + env SNAPPY_STORE_NO_CDN=1 snap known --remote model series=$CORE_SERIES model="$MODEL" brand-id=canonical > "$PREFIX".model-assertion echo "Configured ubuntu-image for the following model assertion:" cat "$PREFIX".model-assertion echo "----------------------------------------------------------" From 1d8aea6f20449a66a733e9ede4d676af9d1b77fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20=27sil2100=27=20Zemczak?= Date: Wed, 3 Oct 2018 11:53:59 +0200 Subject: [PATCH 2/4] Changelog entry --- debian/changelog | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/debian/changelog b/debian/changelog index 0c1e3411..ac42ad52 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +livecd-rootfs (2.542) UNRELEASED; urgency=medium + + * Decide what model assertion series to fetch depending on the suite. Use 16 + for xenial and 18 for other series (bionic+). This enables core18 image + builds. + + -- Ɓukasz 'sil2100' Zemczak Wed, 03 Oct 2018 11:51:59 +0200 + livecd-rootfs (2.541) cosmic; urgency=medium [ Michael Hudson-Doyle ] From 1498baada550d381d1aff7833bc8638b3f4be461 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20=27sil2100=27=20Zemczak?= Date: Wed, 10 Oct 2018 21:57:55 +0200 Subject: [PATCH 3/4] The model assertions for 18 don't actually use series=18 because that would be too logical. --- live-build/auto/config | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/live-build/auto/config b/live-build/auto/config index 7cfd4c17..6d4b9086 100755 --- a/live-build/auto/config +++ b/live-build/auto/config @@ -187,15 +187,17 @@ case $IMAGEFORMAT in esac case $SUITE in xenial) - CORE_SERIES=16 ;; + # Ubuntu Core 16 + ;; *) - CORE_SERIES=18 ;; + # Ubuntu Core 18 + MODEL="ubuntu-core-18-$MODEL" ;; esac echo "IMAGEFORMAT=$IMAGEFORMAT" >> config/common echo "UBUNTU_IMAGE_ARGS=\"$UBUNTU_IMAGE_ARGS\"" >> config/common # Store model assertion in top dir to get it picked up later as a build artifact - env SNAPPY_STORE_NO_CDN=1 snap known --remote model series=$CORE_SERIES model="$MODEL" brand-id=canonical > "$PREFIX".model-assertion + env SNAPPY_STORE_NO_CDN=1 snap known --remote model series=16 model="$MODEL" brand-id=canonical > "$PREFIX".model-assertion echo "Configured ubuntu-image for the following model assertion:" cat "$PREFIX".model-assertion echo "----------------------------------------------------------" From 4f6e5dc11e00b0728efc4ff64d99e9bd45a9ac4d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20=27sil2100=27=20Zemczak?= Date: Thu, 11 Oct 2018 17:12:50 +0200 Subject: [PATCH 4/4] For the pc model, the name changed so we need to special case it a bit. --- live-build/auto/config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/live-build/auto/config b/live-build/auto/config index 6d4b9086..75fd11aa 100755 --- a/live-build/auto/config +++ b/live-build/auto/config @@ -191,7 +191,7 @@ case $IMAGEFORMAT in ;; *) # Ubuntu Core 18 - MODEL="ubuntu-core-18-$MODEL" ;; + MODEL="ubuntu-core-18-${MODEL#pc-}" ;; esac echo "IMAGEFORMAT=$IMAGEFORMAT" >> config/common