[Merge] ~samirakarioh/livecd-rootfs:add-metadata-rocks into livecd-rootfs:ubuntu/master

Athos Ribeiro mp+430736 at code.launchpad.net
Mon Oct 3 17:02:09 UTC 2022



Diff comments:

> diff --git a/live-build/functions b/live-build/functions
> index 3de9857..bf45429 100644
> --- a/live-build/functions
> +++ b/live-build/functions
> @@ -931,6 +932,13 @@ configure_oci() {
>      echo 'exit 101' >> ${chroot}/usr/sbin/policy-rc.d
>      Chroot ${chroot} "chmod +x /usr/sbin/policy-rc.d"
>  
> +
> +    # create a folder /etc/cloud and add a build.info file in it with the serial of the image
> +    mkdir ${chroot}/etc/cloud

I'd rather be more verbose here and perform the additional check. However, I am not familiar with the package codebase and this could indeed be unnecessary. Still, if there are any chances mkdir would fail here, it would be nice to leave some hints when it happens (e.g, was it due to /etc missing, or was $chroot missing?).

> +    cat > ${chroot}/etc/cloud/build.info << EOF
> +serial: $serial
> +EOF
> +
>      # https://github.com/docker/docker/blob/9a9fc01af8fb5d98b8eec0740716226fadb3735c/contrib/mkimage/debootstrap#L54-L56
>      Chroot ${chroot} "dpkg-divert --local --rename --add /sbin/initctl"
>      cp -a ${chroot}/usr/sbin/policy-rc.d ${chroot}/sbin/initctl


-- 
https://code.launchpad.net/~samirakarioh/livecd-rootfs/+git/livecd-rootfs/+merge/430736
Your team Ubuntu Core Development Team is requested to review the proposed merge of ~samirakarioh/livecd-rootfs:add-metadata-rocks into livecd-rootfs:ubuntu/master.




More information about the Ubuntu-reviews mailing list