From 8bf4d3500fc69418f2b67d1dda161bf1d9812514 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Minier?= Date: Wed, 28 Jun 2023 09:13:28 +0000 Subject: [PATCH] Use image definition path rather than making a copy --- live-build/auto/build | 2 +- live-build/auto/config | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/live-build/auto/build b/live-build/auto/build index 824d3a30..5232a38b 100755 --- a/live-build/auto/build +++ b/live-build/auto/build @@ -107,7 +107,7 @@ if [ "${IMAGEFORMAT:-}" = "ubuntu-image" ]; then mv output/seed.manifest "$PREFIX".manifest else /snap/bin/ubuntu-image classic --verbose $UBUNTU_IMAGE_ARGS \ - -O output "$PREFIX".yaml + -O output "$IMAGE_DEFINITION" # Since the output of the ubuntu-image call can vary based on what # kind of an image we build, the safest bet is to 'export' all the # artifacts from the output directory. The image definition file diff --git a/live-build/auto/config b/live-build/auto/config index d2a2b78c..a252d063 100755 --- a/live-build/auto/config +++ b/live-build/auto/config @@ -504,14 +504,14 @@ case $IMAGEFORMAT in IMAGE_PROJECT=$PROJECT [ "$IMAGE_PROJECT" = "ubuntu-cpc" ] && IMAGE_PROJECT="ubuntu-server" - DEFINITION="$IMAGE_PROJECT-$MODEL.yaml" LB_UBUNTU_IMAGES_REPO="${LB_UBUNTU_IMAGES_REPO:-git://git.launchpad.net/ubuntu-images}" LB_UBUNTU_IMAGES_BRANCH="${LB_UBUNTU_IMAGES_BRANCH:-$SUITE}" git clone "$LB_UBUNTU_IMAGES_REPO" -b "$LB_UBUNTU_IMAGES_BRANCH" image-definitions - cp image-definitions/$DEFINITION "$PREFIX".yaml - echo "Configured ubuntu-image for the following image-definition:" - cat "$PREFIX".yaml + IMAGE_DEFINITION="image-definitions/$IMAGE_PROJECT-$MODEL.yaml" + echo "IMAGE_DEFINITION=$IMAGE_DEFINITION" >> config/common + echo "Configured ubuntu-image to use image definition file $IMAGE_DEFINITION which has the following contents:" + cat "$IMAGE_DEFINITION" echo "----------------------------------------------------------" fi