1922 Commits

Author SHA1 Message Date
Balint Reczey
2bb15e03f4 wsl.binary: Add comment about tar usage 2019-05-17 16:41:21 +02:00
Balint Reczey
c8812c7b69 Merge lp:~rbalint/livecd-rootfs -b wsl into ubuntu/master 2019-05-16 22:49:51 +02:00
Balint Reczey
3ae9628528 Build WSL rootfs tarball
LP: #1827930
2019-05-16 18:16:44 +02:00
Dimitri John Ledkov
9d7b6a8e7e Drop maas hook from server-live. 2019-05-16 13:09:25 +02:00
Dimitri John Ledkov
aa58b069ed Set executable bit on kernel-bits.binary 2019-05-16 13:05:56 +02:00
Dimitri John Ledkov
ba49d6db5f Use snap-tool to seed subiquity snap. 2019-05-16 13:03:30 +02:00
Julian Andres Klode
bed915a0fb Don't purge busybox-static in minimized, no longer installed
This caused the builds to fail because we were purging are non
existing package.
2019-05-13 14:22:53 +02:00
Michael Hudson-Doyle
42992467a1 Remove device nodes later for ubuntu-base:minimized (i.e. docker) builds. (LP: #1828118) 2019-05-08 10:04:23 +12:00
Robert C Jennings
bca9242474
ubuntu-cpc: Allow comments in series files and add comments
The addition of disk-image to series files in a prior commit required
some explanation.  Without comment support in series files that was
not possible.  This patch adds support for comments and adds those
comments as well.
2019-05-02 17:15:33 -05:00
Robert C Jennings
05850394d7
ubuntu-cpc: Ensure base disk image is the same between all build targets
The following targets have livecd.ubuntu-cpc.manifest (and
livecd.ubuntu-cpc.ext4) which differ in some way from the 'all'
target. They are all missing grub-efi and other modifications:

root-dir
squashfs
tarball

These targets do not depend on the 'disk-image' target. This means that
the ext4 produced will lack the uefi modifications (and any from the
disk-image target binary hooks).

Since the ext4 file is common to all builds there is a chance that a
parallel build from one of these targets could overwrite this artifact.
This patch ensures that all targets will produce consistent base output.
2019-05-02 16:04:10 -05:00
Robert C Jennings
0bfc5c4290
ubuntu-cpc: Fixup comment references to file names post-parallelization 2019-05-02 15:50:21 -05:00
Julian Andres Klode
ffd06b6e09 Merge branch 'minimize-manual-earlier' of lp:~juliank/livecd-rootfs into ubuntu/master 2019-04-26 10:29:25 +02:00
Dimitri John Ledkov
d13964805e
Fix ubuntu-server-live images to generate initrd with casper UUID. Whilst configs are sources, the variables are not exported into the environment by default. Thus when casper hook is executed, it had no idea that it should generate UUID. 2019-04-25 17:07:02 +01:00
Julian Andres Klode
e95ad81c47 Run clean_debian_chroot after minimize_manual
This avoids us having apt cache files in the final image.

For auto/build, we move the call to clean_debian_chroot to the end,
this also takes care of the caches generated by apt-get update
in case of a preinstalled-pool.

For layered, it's just a simple swap of the lines.

LP: #1826377
2019-04-25 11:51:30 +02:00
Steve Langasek
b83f70a2ea Add support for the 'kassel' subflavor of UC18 images. 2019-04-19 15:24:45 -07:00
Steve Langasek
39f2558b96 Fix the sed script that Tobias had right in the first place and I mangled in the previous upload. 2019-04-13 02:13:17 -07:00
Steve Langasek
f4fa240ed7 Adjust sed command for clarity. 2019-04-12 13:37:02 -07:00
Tobias Koch
79e3123053 Make snapd-explicit-install-stamp a part of the image 2019-04-12 13:37:02 -07:00
Tobias Koch
796211dde7 If image has core18 snaps only, automatically preseed snapd 2019-04-12 13:37:02 -07:00
Tobias Koch
05e71b3840 Do not include any snaps in ubuntu-cpc:minimized builds 2019-04-12 13:37:02 -07:00
Balint Reczey
2d162dd121 Pass --sort=name to tar to make tarballs more reproducible and rsync-friendly 2019-04-10 14:38:35 +02:00
Robert C Jennings
a45342f269
ubuntu-cpc: avoid duplicate snaps listed in qcow manifest
commit a993592 introduced an additional call to create_manifest
(and snap-seed-parse) to write binary/boot/filesystem.packages. This
caused duplicate snap lines in the qcow manifest. This is because the
live-build/auto/binary code assumes that after 'lb binary' is run the
filesystem.packages will only have debs and it calls snap-seed-parse to
add them to the file. The commit changed filesystem.packages in the
ubuntu-cpc uefi binary hook to include debs and snaps.

This patch keeps the intent of the prior patch, updating the
filesystem.packages file for the content of the uefi disk image, but
only writes a listing of debian packages to match the expected content
of filesystem.packages.  The snaps will still be added in generic code
in live-build/auto/build.
2019-03-29 15:39:47 -05:00
Dimitri John Ledkov
036d7d2949
Make serial-subiquity@ use the same codepath as tty1 subiquity.
Such that subiquity runs in the correct environment.
Depends on: https://github.com/CanonicalLtd/subiquity/pull/428
2019-03-21 12:27:15 +00:00
Didier Roche
b20cf752e6 Add languages to live pass
The name of the pass is live and not "ubuntu-live" which is the live pass
default task.
2019-03-20 17:10:05 +01:00
Dimitri John Ledkov
1ab438750d
Revert "subiquity: fix name of mdoules.squashfs to mount"
This reverts commit 98e0b1031d931cbe87f3744613f05557e3bc9acf.
2019-03-20 00:57:41 +00:00
Dimitri John Ledkov
98e0b1031d
subiquity: fix name of mdoules.squashfs to mount
ubuntu-cdimage/debian-cd/tools/add_live_filesystem helpfully adds a
'filesystem.' prefix to the squashfs, hence the name of the file
didn't match what's on disk.
2019-03-18 14:18:27 +00:00
Didier Roche
995f3cf9e0 Ensure default langpacks are removed after installation
Add langpacks to live tasks to have them in the ubiquity diff file and
thus, purged after installation if not selected. (LP: #1818890)
2019-03-18 09:45:47 +01:00
Jean-Baptiste Lallement
38bb0b3301 Fix grub divert for multilayer images
grub-probe must not be called during image build so grub is diverted. In
multilayer image the chroot is always the tip of the filesystem, so we
divert grub at the beginning of each pass and undivdert it as the end.
For flat images, it's diverted just before building the chroot and
undiverted after.
2019-03-18 09:33:07 +01:00
Steve Langasek
e5e1c8dc96 Also don't create the update-motd directory since we're not writing to it.
It will almost certainly be created at some point but we don't need to
create it here.
2019-03-12 12:25:30 -07:00
Steve Langasek
4ca92b04a7 Drop /etc/update-motd.d/51-cloudguest from cloud images; this is not consistent with current Ubuntu Advantage product language. Any future customizations to update-motd for cloud images should be done via a package instead. 2019-03-12 11:47:01 -07:00
Steve Langasek
ea5f01942f divert grub when calling into lb chroot
UbuntuStudio image builds have recently begun failing as a result of adding a
grub theme customization to their flavor, which they then try to apply by
running update-grub from their maintainer scripts.  This fails with:

  Setting up plymouth-theme-ubuntustudio (0.57) ...
  update-alternatives: using /usr/share/plymouth/themes/ubuntustudio-logo/ubuntustudio-logo.plymouth to provide /usr/share/plymouth/themes/default.plymouth (default.plymouth) in auto mode
  update-alternatives: using /usr/share/plymouth/themes/ubuntustudio-text/ubuntustudio-text.plymouth to provide /usr/share/plymouth/themes/text.plymouth (text.plymouth) in auto mode
  update-initramfs: diverted by livecd-rootfs (will be called later)
  /usr/sbin/grub-probe: error: cannot find a device for / (is /dev mounted?).
  dpkg: error processing package plymouth-theme-ubuntustudio (--configure):
   installed plymouth-theme-ubuntustudio package post-installation script subprocess returned error exit status 1

Packages providing grub themes should be able to call update-grub from their
maintainer scripts, and they should be able to be installed under
livecd-rootfs.  It's surprising to me that this hasn't been a problem before
now for any flavors.

We know that grub-probe should not be called as part of an image build, so
just use our standard helper function to divert it before running the chroot
stage and undivert it after.
2019-03-09 20:08:29 +00:00
Steve Langasek
7e4a2627ed Use python3 vmdkstream exclusively; we should not fall back to python2. 2019-02-18 18:06:01 +01:00
Colin Watson
3b22ad381a Make sure buildd images have a /usr/sbin/policy-rc.d symlink
Installing policyrcd-script-zg2 doesn't quite do this because of the way
that live-build installs its own temporary version of policy-rc.d.  The
only remotely sensible way I can see to deal with this is to create the
symlink manually.
2019-02-18 14:58:59 +00:00
Dimitri John Ledkov
a77ec4a9df
Add python3 vmdkstream support 2019-02-18 12:01:25 +01:00
Dimitri John Ledkov
37d9b77b95
subiquity: make subiqutiy_config.mount optional
Remove wants from local-fs.target, add wants from the uuid device instead.

Tested by applying these changes from pre-pivot-root by modifying
/root files in place whilst booting with break=bottom.
2019-02-18 10:26:08 +01:00
Łukasz 'sil2100' Zemczak
8c8b7164d4 Support building pi3-arm64 core18 images. At the same time, make sure we still use the right gadget tree repository for the classic arm64 pi3 image. 2019-02-06 18:11:27 +01:00
Balint Reczey
039ed8ec31 Merge fixing minimized text spacing 2019-02-06 17:55:10 +07:00
Balint Reczey
0182d380ca Nicely separate motd text about minimizing from texts above 2019-02-05 17:24:09 +07:00
Balint Reczey
8a78ab4021 Merge make-rprivate-before-umount 2019-02-05 17:10:49 +07:00
Balint Reczey
96cc185813 Merge feature/parallelization-snap-version-fixing 2019-02-05 17:06:24 +07:00
Didier Roche
1c435c03d2 Fix customized images with multiple brand/models
Some customized images are built from the same chroot, but need to
override brands and models.
2019-02-05 10:13:37 +01:00
Tobias Koch
654fcae467 Replace "snap download" with tool that uses snap store's coherence feature
This is important for parallel image builds to ensure all pre-seeded snaps
have the same versions across image variants.
2019-02-05 10:04:40 +01:00
Balint Reczey
33c5ad0b19 live-build/functions: Always use mount --make-private before umount
Util-linux 2.33 fixed mount --rbind --make-rslave which did not pass MS_REC
with MS_BIND and livecd-rootfs did only --bind --make-rslave effectively with
prior mount versions.
While mount --rbind --rslave are properly passed the flags to mount()
unmounting did not work cleanly with --make-rslave.

To clearly stop propagation of umount, --make-private is used instead of
--make-rslave and it is always set before umounts. Umount -R is replaced
with a simple umount since submounts are tore down in teardown_mountpoint()
earlier.

LP: #1813730
2019-02-05 07:54:37 +07:00
Balint Reczey
a06d208871 Merge branch feature/parallelization-pkg-version-fixing 2019-02-04 23:03:56 +07:00
Colin Watson
305d5cef50 Drop code to handle buildd images for <disco
We'll deal with those in stable updates instead.
2019-02-01 18:07:58 +00:00
Colin Watson
36af2769dc Disable merged /usr in buildd images
Otherwise we might end up building packages with hardcoded paths that
assume a merged /usr.
2019-02-01 18:03:20 +00:00
Tobias Koch
5b70d86f5c Inject a proxy into the build providing a snapshot view of the package repo.
When the REPO_SNAPSHOT_STAMP variable is set, the auto/build script will attempt
to launch a transparent HTTP proxy on port 8080, and insert an iptables rule to
redirect all outgoing HTTP requests to this proxy.

The proxy, contained in the `magic-proxy` Python script, examines each request
and silently overrides those pointing to InRelease files or files that are
listed in InRelease files. It will instead provide the contents of the requested
file as it was at REPO_SNAPSHOT_STAMP, by downloading the corresponding asset
"by hash".
2019-02-01 11:26:20 +01:00
Michael Hudson-Doyle
a9991a908e revert change to ubuntu-server:live snap seeding 2019-02-01 17:22:25 +13:00
Jean-Baptiste Lallement
3dce125d72 Remove inidrd and vmlinuz from live layers after they've been moved to casper 2019-01-31 12:16:07 +01:00
Jean-Baptiste Lallement
f5d3233c64 Fixed wonky indentation 2019-01-31 09:39:22 +01:00