Merge lp:~oddbloke/livecd-rootfs/bionic into lp:~ubuntu-core-dev/livecd-rootfs/bionic-proposed

Proposed by Dan Watkins
Status: Merged
Merged at revision: 1678
Proposed branch: lp:~oddbloke/livecd-rootfs/bionic
Merge into: lp:~ubuntu-core-dev/livecd-rootfs/bionic-proposed
Diff against target: 157 lines (+77/-49)
5 files modified
debian/changelog (+7/-0)
live-build/ubuntu-cpc/hooks/031-0-create-root-dir.binary (+26/-0)
live-build/ubuntu-cpc/hooks/031-1-root-xz.binary (+15/-0)
live-build/ubuntu-cpc/hooks/031-2-root-squashfs.binary (+29/-0)
live-build/ubuntu-cpc/hooks/032-root-squashfs.binary (+0/-49)
To merge this branch: bzr merge lp:~oddbloke/livecd-rootfs/bionic
Reviewer Review Type Date Requested Status
Ubuntu Core Development Team Pending
Review via email: mp+352522@code.launchpad.net
To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/changelog'
--- debian/changelog 2018-08-02 04:00:39 +0000
+++ debian/changelog 2018-08-06 20:28:06 +0000
@@ -1,7 +1,14 @@
1livecd-rootfs (2.525.6) UNRELEASED; urgency=medium1livecd-rootfs (2.525.6) UNRELEASED; urgency=medium
22
3 [ Steve Langasek ]
3 * generate all tar files with --xattrs. LP: #1302192.4 * generate all tar files with --xattrs. LP: #1302192.
45
6 [ Daniel Watkins ]
7 * ubuntu-cpc: Reintroduce the -root.tar.xz artifact (LP: #1585233).
8 * ubuntu-cpc: Generate the root image contents once, and use it for both the
9 -root.tar.xz and the .squashfs.
10 * ubuntu-cpc: Generate -root.tar.xz with --xattrs.
11
5 -- Steve Langasek <steve.langasek@ubuntu.com> Wed, 01 Aug 2018 20:57:14 -070012 -- Steve Langasek <steve.langasek@ubuntu.com> Wed, 01 Aug 2018 20:57:14 -0700
613
7livecd-rootfs (2.525.5) bionic; urgency=medium14livecd-rootfs (2.525.5) bionic; urgency=medium
815
=== added file 'live-build/ubuntu-cpc/hooks/031-0-create-root-dir.binary'
--- live-build/ubuntu-cpc/hooks/031-0-create-root-dir.binary 1970-01-01 00:00:00 +0000
+++ live-build/ubuntu-cpc/hooks/031-0-create-root-dir.binary 2018-08-06 20:28:06 +0000
@@ -0,0 +1,26 @@
1#!/bin/bash -ex
2# vi: ts=4 expandtab
3#
4# Generate the root directory/manifest for rootfs.tar.xz and squashfs
5
6if [ -n "$SUBARCH" ]; then
7 echo "Skipping rootfs build for subarch flavor build"
8 exit 0
9fi
10
11. config/functions
12
13rootfs_dir=rootfs.dir
14mkdir $rootfs_dir
15cp -a chroot/* $rootfs_dir
16
17setup_mountpoint $rootfs_dir
18
19env DEBIAN_FRONTEND=noninteractive chroot $rootfs_dir apt-get --purge remove --assume-yes '^linux-.*' 'linux-base+'
20env DEBIAN_FRONTEND=noninteractive chroot $rootfs_dir apt-get --purge remove --assume-yes '^grub-.*'
21env DEBIAN_FRONTEND=noninteractive chroot $rootfs_dir apt-get autoremove --purge --assume-yes
22rm -rf $rootfs_dir/boot/grub
23
24teardown_mountpoint $rootfs_dir
25
26dpkg-query --admindir=$rootfs_dir/var/lib/dpkg -W > $rootfs_dir.manifest
027
=== added file 'live-build/ubuntu-cpc/hooks/031-1-root-xz.binary'
--- live-build/ubuntu-cpc/hooks/031-1-root-xz.binary 1970-01-01 00:00:00 +0000
+++ live-build/ubuntu-cpc/hooks/031-1-root-xz.binary 2018-08-06 20:28:06 +0000
@@ -0,0 +1,15 @@
1#!/bin/bash -ex
2# vi: ts=4 expandtab
3#
4# Generate the rootfs.tar.xz and manifest
5
6if [ -n "$SUBARCH" ]; then
7 echo "Skipping rootfs build for subarch flavor build"
8 exit 0
9fi
10
11# This is the directory created by 031-0-create-root-dir.binary
12rootfs_dir=rootfs.dir
13
14cp $rootfs_dir.manifest livecd.ubuntu-cpc.rootfs.manifest
15(cd $rootfs_dir/ && tar -c --xattrs *) | xz > livecd.ubuntu-cpc.rootfs.tar.xz
016
=== added file 'live-build/ubuntu-cpc/hooks/031-2-root-squashfs.binary'
--- live-build/ubuntu-cpc/hooks/031-2-root-squashfs.binary 1970-01-01 00:00:00 +0000
+++ live-build/ubuntu-cpc/hooks/031-2-root-squashfs.binary 2018-08-06 20:28:06 +0000
@@ -0,0 +1,29 @@
1#!/bin/bash -ex
2# vi: ts=4 noexpandtab
3#
4# Generate a squashfs root and manifest
5
6case $IMAGE_TARGETS in
7 ""|*squashfs*)
8 ;;
9 *)
10 echo "Skipping squashfs build"
11 exit 0
12 ;;
13esac
14
15if [ -n "$SUBARCH" ]; then
16 echo "Skipping rootfs build for subarch flavor build"
17 exit 0
18fi
19
20# This is the directory created by 031-0-create-root-dir.binary
21rootfs_dir=rootfs.dir
22
23squashfs_f="$PWD/livecd.ubuntu-cpc.squashfs"
24
25cp $rootfs_dir.manifest $squashfs_f.manifest
26
27(cd $rootfs_dir &&
28 mksquashfs . $squashfs_f \
29 -no-progress -xattrs -comp xz )
030
=== removed file 'live-build/ubuntu-cpc/hooks/032-root-squashfs.binary'
--- live-build/ubuntu-cpc/hooks/032-root-squashfs.binary 2018-04-24 16:01:44 +0000
+++ live-build/ubuntu-cpc/hooks/032-root-squashfs.binary 1970-01-01 00:00:00 +0000
@@ -1,49 +0,0 @@
1#!/bin/bash -ex
2# vi: ts=4 noexpandtab
3#
4# Generate a squashfs root and manifest
5
6case $IMAGE_TARGETS in
7 ""|*squashfs*)
8 ;;
9 *)
10 echo "Skipping squashfs build"
11 exit 0
12 ;;
13esac
14
15if [ -n "$SUBARCH" ]; then
16 echo "Skipping rootfs build for subarch flavor build"
17 exit 0
18fi
19
20. config/functions
21
22mkdir binary/boot/squashfs.dir
23cp -a chroot/* binary/boot/squashfs.dir
24
25setup_mountpoint binary/boot/squashfs.dir
26
27chroot binary/boot/squashfs.dir dpkg-divert --local --rename /usr/sbin/grub-probe
28chroot binary/boot/squashfs.dir touch /usr/sbin/grub-probe
29chroot binary/boot/squashfs.dir chmod +x /usr/sbin/grub-probe
30
31env DEBIAN_FRONTEND=noninteractive chroot binary/boot/squashfs.dir apt-get --purge remove --assume-yes '^linux-.*' 'linux-base+'
32env DEBIAN_FRONTEND=noninteractive chroot binary/boot/squashfs.dir apt-get --purge remove --assume-yes '^grub-.*'
33env DEBIAN_FRONTEND=noninteractive chroot binary/boot/squashfs.dir apt-get autoremove --purge --assume-yes
34rm -rf binary/boot/squashfs.dir/boot/grub
35chroot binary/boot/squashfs.dir mkdir -p /lib/modules
36
37chroot binary/boot/squashfs.dir rm /usr/sbin/grub-probe
38chroot binary/boot/squashfs.dir dpkg-divert --remove --local --rename /usr/sbin/grub-probe
39
40teardown_mountpoint binary/boot/squashfs.dir
41
42squashfs_f="${PWD}/livecd.ubuntu-cpc.squashfs"
43squashfs_f_manifest="${squashfs_f}.manifest"
44
45dpkg-query --admindir=binary/boot/squashfs.dir/var/lib/dpkg -W > ${squashfs_f_manifest}
46
47(cd "binary/boot/squashfs.dir/" &&
48 mksquashfs . ${squashfs_f} \
49 -no-progress -xattrs -comp xz )

Subscribers

People subscribed via source and target branches