Merge lp:~jibel/debian-cd/support_for_multilayer_images into lp:~ubuntu-cdimage/debian-cd/ubun3
- support_for_multilayer_images
- Merge into ubun3
Status: | Merged |
---|---|
Merged at revision: | 2020 |
Proposed branch: | lp:~jibel/debian-cd/support_for_multilayer_images |
Merge into: | lp:~ubuntu-cdimage/debian-cd/ubun3 |
Diff against target: |
308 lines (+78/-54) 6 files modified
Makefile (+8/-1) tools/add_live_filesystem (+30/-35) tools/boot/disco/boot-amd64 (+12/-10) tools/boot/disco/boot-arm64 (+9/-7) tools/boot/disco/boot-s390x (+3/-1) tools/boot/disco/common.sh (+16/-0) |
To merge this branch: | bzr merge lp:~jibel/debian-cd/support_for_multilayer_images |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Steve Langasek | Approve | ||
Review via email: mp+359228@code.launchpad.net |
Commit message
Support for multi layers images
- Do not hardcode build artifact names.
- Download build artifacts to their own subdirectory for multilayer images
- Keep backward compatibility with "flat" images
- Add boot option layerfs-path for images that support casper to boot multilayer images
Description of the change
- 2007. By Adam Conrad
-
[xnox, r=adconrad] server-live: fixup s390x iso boot
- 2008. By Steve Langasek
- 2009. By Steve Langasek
Jean-Baptiste Lallement (jibel) wrote : | # |
Jean-Baptiste Lallement (jibel) wrote : | # |
Merged lp:~jibel/debian-cd/rename_artefacts_made_generic :
* Makefile, tools/add_
* tools/add_
- 2010. By Adam Conrad
-
bionic: DEBVERSION=18.04.2, Release->Beta
- 2011. By Adam Conrad
-
bionic: BACKPORT_
KERNEL= "hwe-18. 04" - 2012. By Adam Conrad
-
Forward-port r1965 to all newer series.
Jean-Baptiste Lallement (jibel) wrote : | # |
This last update adds the option layerfs-path to boot a multi-layer image.
- 2013. By Adam Conrad
-
bionic: Beta->Release
- 2014. By Adam Conrad
-
bionic: Add HWE bootloader bits to live-server.
- 2015. By Adam Conrad
-
bionic: Release->Beta
- 2016. By Łukasz Zemczak
-
xenial: DEBVERSION=16.04.6
- 2017. By Łukasz Zemczak
-
trusty: DEBVERSION=14.04.6
Steve Langasek (vorlon) wrote : | # |
This needs rebased against current trunk - in particular, revno 2014 introduces changes to add handling of hwe squashfs in addition to generic, which I noticed because the squashfs-generic handling in your branch doesn't handle the other possible kernel flavors that I expected it to.
- 2018. By Steve Langasek
-
Prune dead code: we never produce artifacts called vmlinuz*.efi.signed with recent versions of livecd-rootfs, just expect our input filename to be sensible
- 2019. By Steve Langasek
- 2020. By Jean-Baptiste Lallement
-
Rebased on trunk r2014
- 2021. By Jean-Baptiste Lallement
-
- Removed possible unecessary double-spaces on kernel command line
- fixed typo in comment - 2022. By Jean-Baptiste Lallement
-
Do not ignore failures from ln
- 2023. By Jean-Baptiste Lallement
-
Be more on strict on squashfs-generic extension match
- 2024. By Jean-Baptiste Lallement
-
Revert unmkinitramfs specialization
Didier Roche-Tolomelli (didrocks) : | # |
Jean-Baptiste Lallement (jibel) wrote : | # |
Thanks for the review.
The branch has been rebased on trunk and updated according to your comments.
We tested a build or ubuntu-desktop.
Steve Langasek (vorlon) wrote : | # |
thanks, only minor changes requested.
- 2025. By Jean-Baptiste Lallement
-
* Explain non-obvious file naming in file renaming code
* Changed globing of *.squashfs-generic
Didier Roche-Tolomelli (didrocks) wrote : | # |
New pushed version should address previous comments.
Steve Langasek (vorlon) : | # |
Preview Diff
1 | === modified file 'Makefile' | |||
2 | --- Makefile 2018-02-23 13:07:01 +0000 | |||
3 | +++ Makefile 2019-03-12 08:32:44 +0000 | |||
4 | @@ -252,7 +252,11 @@ | |||
5 | 252 | ifeq ($(PROJECT),kubuntu-mobile) | 252 | ifeq ($(PROJECT),kubuntu-mobile) |
6 | 253 | CDBASE = $(CODENAME)-mobile-$(FULLARCH) | 253 | CDBASE = $(CODENAME)-mobile-$(FULLARCH) |
7 | 254 | else | 254 | else |
8 | 255 | ifeq ($(SUBPROJECT),canary) | ||
9 | 256 | CDBASE = $(CODENAME)-desktop-canary-$(FULLARCH) | ||
10 | 257 | else | ||
11 | 255 | CDBASE = $(CODENAME)-desktop-$(FULLARCH) | 258 | CDBASE = $(CODENAME)-desktop-$(FULLARCH) |
12 | 259 | endif | ||
13 | 256 | endif | 260 | endif |
14 | 257 | endif | 261 | endif |
15 | 258 | endif | 262 | endif |
16 | @@ -1105,7 +1109,10 @@ | |||
17 | 1105 | fi; \ | 1109 | fi; \ |
18 | 1106 | done | 1110 | done |
19 | 1107 | ifeq ($(LIVE_FILESYSTEM),1) | 1111 | ifeq ($(LIVE_FILESYSTEM),1) |
21 | 1108 | -cp -a $(LIVEIMAGES)/$(FULLARCH).manifest $(OUT)/$(call CDBASE,$$n).manifest | 1112 | -for p in $(LIVEIMAGES)/$(FULLARCH)*.manifest; do \ |
22 | 1113 | f=`basename $$p`; \ | ||
23 | 1114 | cp -a $$p $(OUT)/$(call CDBASE,$$n).`echo $$f|cut -d. -f2-`; \ | ||
24 | 1115 | done | ||
25 | 1109 | -if [ -e $(LIVEIMAGES)/$(FULLARCH).manifest-remove ]; then \ | 1116 | -if [ -e $(LIVEIMAGES)/$(FULLARCH).manifest-remove ]; then \ |
26 | 1110 | cp -a $(LIVEIMAGES)/$(FULLARCH).manifest-remove $(OUT)/$(call CDBASE,$$n).manifest-remove; \ | 1117 | cp -a $(LIVEIMAGES)/$(FULLARCH).manifest-remove $(OUT)/$(call CDBASE,$$n).manifest-remove; \ |
27 | 1111 | elif [ -e $(LIVEIMAGES)/$(FULLARCH).manifest-desktop ]; then \ | 1118 | elif [ -e $(LIVEIMAGES)/$(FULLARCH).manifest-desktop ]; then \ |
28 | 1112 | 1119 | ||
29 | === modified file 'tools/add_live_filesystem' | |||
30 | --- tools/add_live_filesystem 2019-02-14 06:07:23 +0000 | |||
31 | +++ tools/add_live_filesystem 2019-03-12 08:32:44 +0000 | |||
32 | @@ -10,40 +10,36 @@ | |||
33 | 10 | mkdir -p "$BDIR/CD1/$DIR" | 10 | mkdir -p "$BDIR/CD1/$DIR" |
34 | 11 | if [ -e "$LIVEIMAGES/$FULLARCH.cloop" ]; then | 11 | if [ -e "$LIVEIMAGES/$FULLARCH.cloop" ]; then |
35 | 12 | ln "$LIVEIMAGES/$FULLARCH.cloop" "$BDIR/CD1/$DIR/filesystem.cloop" | 12 | ln "$LIVEIMAGES/$FULLARCH.cloop" "$BDIR/CD1/$DIR/filesystem.cloop" |
70 | 13 | elif [ -e "$LIVEIMAGES/$FULLARCH.squashfs" ]; then | 13 | elif [ -n "$(ls $LIVEIMAGES/$FULLARCH*.squashfs 2>/dev/null)" ]; then |
71 | 14 | ln "$LIVEIMAGES/$FULLARCH.squashfs" "$BDIR/CD1/$DIR/filesystem.squashfs" | 14 | for ext in squashfs squashfs.gpg modules.squashfs-generic modules.squashfs-generic-hwe size manifest; do |
72 | 15 | if [ -e "$LIVEIMAGES/$FULLARCH.size" ]; then | 15 | for origfilename in $(ls $LIVEIMAGES/$FULLARCH*.$ext 2>/dev/null); do |
73 | 16 | ln "$LIVEIMAGES/$FULLARCH.size" "$BDIR/CD1/$DIR/filesystem.size" | 16 | # Strip fullarch from file basename and optionally prepend "filesystem." |
74 | 17 | fi | 17 | # For instance: |
75 | 18 | if [ -e "$LIVEIMAGES/$FULLARCH.squashfs.gpg" ]; then | 18 | # <arch>.filename.<ext> -> filename.<ext> |
76 | 19 | ln "$LIVEIMAGES/$FULLARCH.squashfs.gpg" "$BDIR/CD1/$DIR/filesystem.squashfs.gpg" | 19 | # <arch>.<ext> -> filesystem.<ext> |
77 | 20 | fi | 20 | origfilename="$(basename ${origfilename})" |
78 | 21 | if [ -e "$LIVEIMAGES/$FULLARCH.maas-rack.squashfs" ]; then | 21 | filename=${origfilename#$FULLARCH.} |
79 | 22 | mkdir -p "$BDIR/CD1/$DIR/maas/" | 22 | if [ "$filename" = "$ext" ]; then |
80 | 23 | ln "$LIVEIMAGES/$FULLARCH.maas-rack.squashfs" "$BDIR/CD1/$DIR/maas/maas-rack.squashfs" | 23 | filename="filesystem.$filename" |
81 | 24 | fi | 24 | fi |
82 | 25 | if [ -e "$LIVEIMAGES/$FULLARCH.maas-region.squashfs" ]; then | 25 | |
83 | 26 | mkdir -p "$BDIR/CD1/$DIR/maas/" | 26 | # Copy in squashfs corresponding subdirectory for multi-layer with sublayers system |
84 | 27 | ln "$LIVEIMAGES/$FULLARCH.maas-region.squashfs" "$BDIR/CD1/$DIR/maas/maas-region.squashfs" | 27 | case $filename in |
85 | 28 | fi | 28 | maas*) |
86 | 29 | if [ -e "$LIVEIMAGES/$FULLARCH.modules.squashfs-generic" ]; then | 29 | filepath="maas/$filename" |
87 | 30 | mkdir -p "$BDIR/CD1/$DIR/extras/" | 30 | ;; |
88 | 31 | ln "$LIVEIMAGES/$FULLARCH.modules.squashfs-generic" "$BDIR/CD1/$DIR/extras/modules.squashfs-generic" | 31 | *.modules.squashfs-*) |
89 | 32 | fi | 32 | filepath="extras/$filename" |
90 | 33 | if [ -e "$LIVEIMAGES/$FULLARCH.modules.squashfs-generic-hwe" ]; then | 33 | ;; |
91 | 34 | mkdir -p "$BDIR/CD1/$DIR/extras/" | 34 | *) |
92 | 35 | ln "$LIVEIMAGES/$FULLARCH.modules.squashfs-generic-hwe" "$BDIR/CD1/$DIR/extras/modules.squashfs-generic-hwe" | 35 | filepath="$filename" |
93 | 36 | fi | 36 | ;; |
94 | 37 | 37 | esac | |
95 | 38 | if [ -e "$LIVEIMAGES/$FULLARCH.installer.squashfs" ]; then | 38 | |
96 | 39 | ln "$LIVEIMAGES/$FULLARCH.installer.squashfs" "$BDIR/CD1/$DIR/installer.squashfs" | 39 | mkdir -p $BDIR/CD1/$DIR/$(dirname "$filepath") |
97 | 40 | if [ -e "$LIVEIMAGES/$FULLARCH.installer.size" ]; then | 40 | ln "$LIVEIMAGES/$origfilename" "$BDIR/CD1/$DIR/$filepath" |
98 | 41 | ln "$LIVEIMAGES/$FULLARCH.installer.size" "$BDIR/CD1/$DIR/installer.size" | 41 | done |
99 | 42 | fi | 42 | done |
66 | 43 | if [ -e "$LIVEIMAGES/$FULLARCH.installer.squashfs.gpg" ]; then | ||
67 | 44 | ln "$LIVEIMAGES/$FULLARCH.installer.squashfs.gpg" "$BDIR/CD1/$DIR/installer.squashfs.gpg" | ||
68 | 45 | fi | ||
69 | 46 | fi | ||
100 | 47 | else | 43 | else |
101 | 48 | echo "No filesystem for $FULLARCH!" >&2 | 44 | echo "No filesystem for $FULLARCH!" >&2 |
102 | 49 | fi | 45 | fi |
103 | @@ -57,7 +53,6 @@ | |||
104 | 57 | fi | 53 | fi |
105 | 58 | done | 54 | done |
106 | 59 | done | 55 | done |
107 | 60 | ln "$LIVEIMAGES/$FULLARCH.manifest" "$BDIR/CD1/$DIR/filesystem.manifest" || true | ||
108 | 61 | if [ -e "$LIVEIMAGES/$FULLARCH.manifest-remove" ]; then | 56 | if [ -e "$LIVEIMAGES/$FULLARCH.manifest-remove" ]; then |
109 | 62 | ln "$LIVEIMAGES/$FULLARCH.manifest-remove" "$BDIR/CD1/$DIR/filesystem.manifest-remove" || true | 57 | ln "$LIVEIMAGES/$FULLARCH.manifest-remove" "$BDIR/CD1/$DIR/filesystem.manifest-remove" || true |
110 | 63 | elif [ -e "$LIVEIMAGES/$FULLARCH.manifest-desktop" ]; then | 58 | elif [ -e "$LIVEIMAGES/$FULLARCH.manifest-desktop" ]; then |
111 | 64 | 59 | ||
112 | === modified file 'tools/boot/disco/boot-amd64' | |||
113 | --- tools/boot/disco/boot-amd64 2019-03-08 16:59:14 +0000 | |||
114 | +++ tools/boot/disco/boot-amd64 2019-03-12 08:32:44 +0000 | |||
115 | @@ -440,23 +440,25 @@ | |||
116 | 440 | liveparams= | 440 | liveparams= |
117 | 441 | esac | 441 | esac |
118 | 442 | 442 | ||
119 | 443 | LAYERFS_PATH_OPT=$(add_layerfs_path_opt) | ||
120 | 444 | |||
121 | 443 | cat >> boot$N/isolinux/txt.cfg <<EOF | 445 | cat >> boot$N/isolinux/txt.cfg <<EOF |
122 | 444 | label live | 446 | label live |
123 | 445 | menu label $livelabel | 447 | menu label $livelabel |
124 | 446 | kernel $CASPER_KERNEL | 448 | kernel $CASPER_KERNEL |
126 | 447 | append $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams initrd=$CASPER_INITRD $QUIET $SPLASH --- | 449 | append $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams$LAYERFS_PATH_OPT initrd=$CASPER_INITRD $QUIET $SPLASH --- |
127 | 448 | EOF | 450 | EOF |
128 | 449 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF | 451 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF |
129 | 450 | menuentry "${livelabel#^}" { | 452 | menuentry "${livelabel#^}" { |
130 | 451 | set gfxpayload=keep | 453 | set gfxpayload=keep |
132 | 452 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams $QUIET $SPLASH --- | 454 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams$LAYERFS_PATH_OPT $QUIET $SPLASH --- |
133 | 453 | initrd $CASPER_INITRD | 455 | initrd $CASPER_INITRD |
134 | 454 | } | 456 | } |
135 | 455 | EOF | 457 | EOF |
136 | 456 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF | 458 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF |
137 | 457 | menuentry "${livelabel#^}" { | 459 | menuentry "${livelabel#^}" { |
138 | 458 | set gfxpayload=keep | 460 | set gfxpayload=keep |
140 | 459 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams iso-scan/filename=\${iso_path} $QUIET $SPLASH --- | 461 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams$LAYERFS_PATH_OPT iso-scan/filename=\${iso_path} $QUIET $SPLASH --- |
141 | 460 | initrd $CASPER_INITRD | 462 | initrd $CASPER_INITRD |
142 | 461 | } | 463 | } |
143 | 462 | EOF | 464 | EOF |
144 | @@ -465,18 +467,18 @@ | |||
145 | 465 | label live-install | 467 | label live-install |
146 | 466 | menu label ^Install $HUMANPROJECT | 468 | menu label ^Install $HUMANPROJECT |
147 | 467 | kernel $CASPER_KERNEL | 469 | kernel $CASPER_KERNEL |
149 | 468 | append $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper only-ubiquity initrd=$CASPER_INITRD $QUIET $SPLASH --- | 470 | append $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$LAYERFS_PATH_OPT only-ubiquity initrd=$CASPER_INITRD $QUIET $SPLASH --- |
150 | 469 | EOF | 471 | EOF |
151 | 470 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF | 472 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF |
152 | 471 | menuentry "Install $HUMANPROJECT" { | 473 | menuentry "Install $HUMANPROJECT" { |
153 | 472 | set gfxpayload=keep | 474 | set gfxpayload=keep |
155 | 473 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper only-ubiquity $QUIET $SPLASH --- | 475 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$LAYERFS_PATH_OPT only-ubiquity $QUIET $SPLASH --- |
156 | 474 | initrd $CASPER_INITRD | 476 | initrd $CASPER_INITRD |
157 | 475 | } | 477 | } |
158 | 476 | EOF | 478 | EOF |
159 | 477 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF | 479 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF |
160 | 478 | menuentry "Install $HUMANPROJECT" { | 480 | menuentry "Install $HUMANPROJECT" { |
162 | 479 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper only-ubiquity iso-scan/filename=\${iso_path} $QUIET $SPLASH --- | 481 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$LAYERFS_PATH_OPT only-ubiquity iso-scan/filename=\${iso_path} $QUIET $SPLASH --- |
163 | 480 | initrd $CASPER_INITRD | 482 | initrd $CASPER_INITRD |
164 | 481 | } | 483 | } |
165 | 482 | EOF | 484 | EOF |
166 | @@ -556,7 +558,7 @@ | |||
167 | 556 | cat >> $CDDIR/boot/grub/${!kp}grub.cfg <<EOF | 558 | cat >> $CDDIR/boot/grub/${!kp}grub.cfg <<EOF |
168 | 557 | menuentry "OEM install (for manufacturers)" { | 559 | menuentry "OEM install (for manufacturers)" { |
169 | 558 | set gfxpayload=keep | 560 | set gfxpayload=keep |
171 | 559 | linux $CASPER_KERNEL $KERNEL_PARAMS ${DEFAULT_PRESEED/$PREFIX_PRESEED/$PREFIX_PRESEED${!kp}} boot=casper only-ubiquity quiet splash oem-config/enable=true --- | 561 | linux $CASPER_KERNEL $KERNEL_PARAMS ${DEFAULT_PRESEED/$PREFIX_PRESEED/$PREFIX_PRESEED${!kp}} boot=casper$LAYERFS_PATH_OPT only-ubiquity quiet splash oem-config/enable=true --- |
172 | 560 | initrd $CASPER_INITRD | 562 | initrd $CASPER_INITRD |
173 | 561 | } | 563 | } |
174 | 562 | EOF | 564 | EOF |
175 | @@ -640,18 +642,18 @@ | |||
176 | 640 | label check | 642 | label check |
177 | 641 | menu label ^Check disc for defects | 643 | menu label ^Check disc for defects |
178 | 642 | kernel $CASPER_KERNEL | 644 | kernel $CASPER_KERNEL |
180 | 643 | append $KERNEL_PARAMS boot=casper integrity-check initrd=$CASPER_INITRD quiet splash --- | 645 | append $KERNEL_PARAMS boot=casper$LAYERFS_PATH_OPT integrity-check initrd=$CASPER_INITRD quiet splash --- |
181 | 644 | EOF | 646 | EOF |
182 | 645 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF | 647 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF |
183 | 646 | menuentry "Check disc for defects" { | 648 | menuentry "Check disc for defects" { |
184 | 647 | set gfxpayload=keep | 649 | set gfxpayload=keep |
186 | 648 | linux $CASPER_KERNEL $KERNEL_PARAMS boot=casper integrity-check quiet splash --- | 650 | linux $CASPER_KERNEL $KERNEL_PARAMS boot=casper$LAYERFS_PATH_OPT integrity-check quiet splash --- |
187 | 649 | initrd $CASPER_INITRD | 651 | initrd $CASPER_INITRD |
188 | 650 | } | 652 | } |
189 | 651 | EOF | 653 | EOF |
190 | 652 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF | 654 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF |
191 | 653 | menuentry "Check disc for defects" { | 655 | menuentry "Check disc for defects" { |
193 | 654 | linux $CASPER_KERNEL $KERNEL_PARAMS boot=casper integrity-check iso-scan/filename=\${iso_path} quiet splash --- | 656 | linux $CASPER_KERNEL $KERNEL_PARAMS boot=casper$LAYERFS_PATH_OPT integrity-check iso-scan/filename=\${iso_path} quiet splash --- |
194 | 655 | initrd $CASPER_INITRD | 657 | initrd $CASPER_INITRD |
195 | 656 | } | 658 | } |
196 | 657 | EOF | 659 | EOF |
197 | 658 | 660 | ||
198 | === modified file 'tools/boot/disco/boot-arm64' | |||
199 | --- tools/boot/disco/boot-arm64 2018-10-30 13:12:35 +0000 | |||
200 | +++ tools/boot/disco/boot-arm64 2019-03-12 08:32:44 +0000 | |||
201 | @@ -163,6 +163,8 @@ | |||
202 | 163 | EOF | 163 | EOF |
203 | 164 | fi | 164 | fi |
204 | 165 | 165 | ||
205 | 166 | LAYERFS_PATH_OPT=$(add_layerfs_path_opt) | ||
206 | 167 | |||
207 | 166 | if [ "$CDIMAGE_LIVE" = 1 ]; then | 168 | if [ "$CDIMAGE_LIVE" = 1 ]; then |
208 | 167 | if [ "$PROJECT" = kubuntu ] || [ "$PROJECT" = kubuntu-plasma5 ]; then | 169 | if [ "$PROJECT" = kubuntu ] || [ "$PROJECT" = kubuntu-plasma5 ]; then |
209 | 168 | livelabel="^Start $HUMANPROJECT" | 170 | livelabel="^Start $HUMANPROJECT" |
210 | @@ -174,14 +176,14 @@ | |||
211 | 174 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF | 176 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF |
212 | 175 | menuentry "${livelabel#^}" { | 177 | menuentry "${livelabel#^}" { |
213 | 176 | set gfxpayload=keep | 178 | set gfxpayload=keep |
215 | 177 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams quiet splash --- | 179 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams$LAYERFS_PATH_OPT quiet splash --- |
216 | 178 | initrd $CASPER_INITRD | 180 | initrd $CASPER_INITRD |
217 | 179 | } | 181 | } |
218 | 180 | EOF | 182 | EOF |
219 | 181 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF | 183 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF |
220 | 182 | menuentry "${livelabel#^}" { | 184 | menuentry "${livelabel#^}" { |
221 | 183 | set gfxpayload=keep | 185 | set gfxpayload=keep |
223 | 184 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams iso-scan/filename=\${iso_path} quiet splash --- | 186 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$liveparams$LAYERFS_PATH_OPT iso-scan/filename=\${iso_path} quiet splash --- |
224 | 185 | initrd $CASPER_INITRD | 187 | initrd $CASPER_INITRD |
225 | 186 | } | 188 | } |
226 | 187 | EOF | 189 | EOF |
227 | @@ -189,13 +191,13 @@ | |||
228 | 189 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF | 191 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF |
229 | 190 | menuentry "Install $HUMANPROJECT" { | 192 | menuentry "Install $HUMANPROJECT" { |
230 | 191 | set gfxpayload=keep | 193 | set gfxpayload=keep |
232 | 192 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper only-ubiquity quiet splash --- | 194 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$LAYERFS_PATH_OPT only-ubiquity quiet splash --- |
233 | 193 | initrd $CASPER_INITRD | 195 | initrd $CASPER_INITRD |
234 | 194 | } | 196 | } |
235 | 195 | EOF | 197 | EOF |
236 | 196 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF | 198 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF |
237 | 197 | menuentry "Install $HUMANPROJECT" { | 199 | menuentry "Install $HUMANPROJECT" { |
239 | 198 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper only-ubiquity iso-scan/filename=\${iso_path} quiet splash --- | 200 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$LAYERFS_PATH_OPT only-ubiquity iso-scan/filename=\${iso_path} quiet splash --- |
240 | 199 | initrd $CASPER_INITRD | 201 | initrd $CASPER_INITRD |
241 | 200 | } | 202 | } |
242 | 201 | EOF | 203 | EOF |
243 | @@ -230,7 +232,7 @@ | |||
244 | 230 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF | 232 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF |
245 | 231 | menuentry "OEM install (for manufacturers)" { | 233 | menuentry "OEM install (for manufacturers)" { |
246 | 232 | set gfxpayload=keep | 234 | set gfxpayload=keep |
248 | 233 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper only-ubiquity quiet splash oem-config/enable=true --- | 235 | linux $CASPER_KERNEL $KERNEL_PARAMS $DEFAULT_PRESEED boot=casper$LAYERFS_PATH_OPT only-ubiquity quiet splash oem-config/enable=true --- |
249 | 234 | initrd $CASPER_INITRD | 236 | initrd $CASPER_INITRD |
250 | 235 | } | 237 | } |
251 | 236 | EOF | 238 | EOF |
252 | @@ -268,13 +270,13 @@ | |||
253 | 268 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF | 270 | cat >> $CDDIR/boot/grub/grub.cfg <<EOF |
254 | 269 | menuentry "Check disc for defects" { | 271 | menuentry "Check disc for defects" { |
255 | 270 | set gfxpayload=keep | 272 | set gfxpayload=keep |
257 | 271 | linux $CASPER_KERNEL $KERNEL_PARAMS boot=casper integrity-check quiet splash --- | 273 | linux $CASPER_KERNEL $KERNEL_PARAMS boot=casper$LAYERFS_PATH_OPT integrity-check quiet splash --- |
258 | 272 | initrd $CASPER_INITRD | 274 | initrd $CASPER_INITRD |
259 | 273 | } | 275 | } |
260 | 274 | EOF | 276 | EOF |
261 | 275 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF | 277 | cat >> $CDDIR/boot/grub/loopback.cfg <<EOF |
262 | 276 | menuentry "Check disc for defects" { | 278 | menuentry "Check disc for defects" { |
264 | 277 | linux $CASPER_KERNEL $KERNEL_PARAMS boot=casper integrity-check iso-scan/filename=\${iso_path} quiet splash --- | 279 | linux $CASPER_KERNEL $KERNEL_PARAMS boot=casper$LAYERFS_PATH_OPT integrity-check iso-scan/filename=\${iso_path} quiet splash --- |
265 | 278 | initrd $CASPER_INITRD | 280 | initrd $CASPER_INITRD |
266 | 279 | } | 281 | } |
267 | 280 | EOF | 282 | EOF |
268 | 281 | 283 | ||
269 | === modified file 'tools/boot/disco/boot-s390x' | |||
270 | --- tools/boot/disco/boot-s390x 2018-12-23 18:12:29 +0000 | |||
271 | +++ tools/boot/disco/boot-s390x 2019-03-12 08:32:44 +0000 | |||
272 | @@ -53,9 +53,11 @@ | |||
273 | 53 | cp -lf "$DI_DIR/generic/initrd.off" $imagedir | 53 | cp -lf "$DI_DIR/generic/initrd.off" $imagedir |
274 | 54 | cp -lf "$DI_DIR/generic/initrd.siz" $imagedir | 54 | cp -lf "$DI_DIR/generic/initrd.siz" $imagedir |
275 | 55 | 55 | ||
276 | 56 | LAYERFS_PATH_OPT=$(add_layerfs_path_opt) | ||
277 | 57 | |||
278 | 56 | # For server-live images, use casper's initrd and kernel instead | 58 | # For server-live images, use casper's initrd and kernel instead |
279 | 57 | if [ "$CDIMAGE_LIVE" = 1 ]; then | 59 | if [ "$CDIMAGE_LIVE" = 1 ]; then |
281 | 58 | CMDLINE="boot=casper --- quiet" | 60 | CMDLINE="boot=casper$LAYERFS_PATH_OPT --- quiet" |
282 | 59 | mv $CDDIR/casper/filesystem.initrd-generic $imagedir/initrd.ubuntu | 61 | mv $CDDIR/casper/filesystem.initrd-generic $imagedir/initrd.ubuntu |
283 | 60 | mv $CDDIR/casper/filesystem.kernel-generic $imagedir/kernel.ubuntu | 62 | mv $CDDIR/casper/filesystem.kernel-generic $imagedir/kernel.ubuntu |
284 | 61 | echo "$CMDLINE" > $imagedir/parmfile.ubuntu | 63 | echo "$CMDLINE" > $imagedir/parmfile.ubuntu |
285 | 62 | 64 | ||
286 | === modified file 'tools/boot/disco/common.sh' | |||
287 | --- tools/boot/disco/common.sh 2018-10-30 13:12:35 +0000 | |||
288 | +++ tools/boot/disco/common.sh 2019-03-12 08:32:44 +0000 | |||
289 | @@ -158,3 +158,19 @@ | |||
290 | 158 | echo -n "$NEW_OPT " >> $OPTS_FILE | 158 | echo -n "$NEW_OPT " >> $OPTS_FILE |
291 | 159 | fi | 159 | fi |
292 | 160 | } | 160 | } |
293 | 161 | |||
294 | 162 | # for multi-layer images, add a kernel command line option to set layerfs-path | ||
295 | 163 | # and select the leaf filesystem to determine the list of layers to merge in | ||
296 | 164 | # an overlay and boot from. | ||
297 | 165 | add_layerfs_path_opt() { | ||
298 | 166 | case $PROJECT in | ||
299 | 167 | ubuntu) | ||
300 | 168 | if [ "$SUBPROJECT" = "canary" ]; then | ||
301 | 169 | echo ' layerfs-path=minimal.standard.live.squashfs' | ||
302 | 170 | return | ||
303 | 171 | fi | ||
304 | 172 | ;; | ||
305 | 173 | *) | ||
306 | 174 | ;; | ||
307 | 175 | esac | ||
308 | 176 | } |
Merged trunk.