[Merge] lp:~sil2100/livecd-rootfs/xenial-ui-support-and-core-suite into lp:~ubuntu-core-dev/livecd-rootfs/xenial-proposed

Steve Langasek steve.langasek at canonical.com
Fri Oct 26 21:39:20 UTC 2018


Review: Needs Fixing



Diff comments:

> 
> === modified file 'debian/control'
> --- debian/control	2018-06-07 21:54:23 +0000
> +++ debian/control	2018-10-24 15:55:23 +0000
> @@ -30,7 +30,9 @@
>           python3-software-properties,
>           qemu-utils,
>           rsync,
> +         snapd,
>           squashfs-tools (>= 1:3.3-1),
> +         ubuntu-image,

bionic also has added a build-dependency on sudo as part of the ubuntu-image support.  Is that needed here?

>           vmdk-stream-converter [amd64 i386],
>           xz-utils,
>           zerofree
> 
> === modified file 'live-build/auto/build'
> --- live-build/auto/build	2018-07-02 21:43:35 +0000
> +++ live-build/auto/build	2018-10-24 15:55:23 +0000
> @@ -10,6 +10,28 @@
>  Read_conffiles config/all config/common config/bootstrap config/chroot config/binary config/source
>  Set_defaults
>  
> +if [ -z "${PROJECT:-}" ]; then
> +    echo "PROJECT environment variable has to be set" >&2
> +    exit 1
> +fi
> +
> +. config/functions
> +
> +# Link output files somewhere BuildLiveCD will be able to find them.
> +PREFIX="livecd.$PROJECT${SUBARCH:+-$SUBARCH}"

Note that this assignment is now duplicated further down in the file (in bionic this was a move, not an addition).  The duplicate assignment lower down should be deleted as part of this merge.

> +
> +if [ "${IMAGEFORMAT:-}" = "ubuntu-image" ]; then
> +	# Use ubuntu-image instead of live-build
> +
> +	CHANNEL="${CHANNEL:-edge}"
> +	env SNAPPY_STORE_NO_CDN=1 \
> +	ubuntu-image -c "$CHANNEL" $UBUNTU_IMAGE_ARGS \
> +		-o "$PREFIX".img "$PREFIX".model-assertion
> +	xz -0 -T4 "$PREFIX".img
> +	mv seed.manifest "$PREFIX".manifest
> +	exit 0
> +fi
> +
>  # Setup cleanup function
>  Setup_cleanup
>  
> 
> === modified file 'live-build/auto/config'
> --- live-build/auto/config	2018-06-08 16:12:22 +0000
> +++ live-build/auto/config	2018-10-24 15:55:23 +0000
> @@ -144,6 +145,53 @@
>  		PREINSTALLED=true
>  		;;
>  
> +	ubuntu-image)
> +		case "$ARCH+${SUBARCH:-}" in
> +			amd64+*)
> +				MODEL=pc-amd64 ;;
> +			i386+*)
> +				MODEL=pc-i386 ;;
> +			arm64+snapdragon)
> +				MODEL=dragonboard ;;
> +			armhf+raspi2)
> +				MODEL=pi2 ;;
> +			armhf+raspi3)
> +				MODEL=pi3 ;;
> +			armhf+cm3)
> +				MODEL=cm3 ;;
> +			*)
> +				echo "Model $ARCH+${SUBARCH:-} unknown to livecd-rootfs" >&2
> +				exit 1
> +				;;
> +		esac
> +		case $MODEL in
> +			pc-amd64|pc-i386)
> +				UBUNTU_IMAGE_ARGS="--image-size 3700M" ;;
> +			*)
> +				UBUNTU_IMAGE_ARGS="" ;;
> +		esac
> +		case $SUITE in
> +			xenial)
> +				# Ubuntu Core 16
> +				;;
> +			*)
> +				# Ubuntu Core 18
> +				MODEL="ubuntu-core-18-${MODEL#pc-}" ;;
> +		esac

I am very confused because the above case statement is absent on the bionic branch, where it would seem to be mandatory, yet we are currently building core 18 dailies against bionic.  So how does this code not match the bionic branch?

> +
> +		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
> +		echo "Configured ubuntu-image for the following model assertion:"
> +		cat "$PREFIX".model-assertion
> +		echo "----------------------------------------------------------"
> +		# Fake finished configuration for lb build
> +		mkdir -p .build
> +		touch .build/config
> +		exit 0
> +		;;
> +
>  	none)
>  		OPTS="${OPTS:+$OPTS }--chroot-filesystem $IMAGEFORMAT"
>  		;;


-- 
https://code.launchpad.net/~sil2100/livecd-rootfs/xenial-ui-support-and-core-suite/+merge/356150
Your team Ubuntu Core Development Team is subscribed to branch lp:~ubuntu-core-dev/livecd-rootfs/xenial-proposed.



More information about the Ubuntu-reviews mailing list