Commit Graph

6677 Commits

Author SHA1 Message Date
Olivier Gayot bd59804c36 snapcraft: bump curtin rev for conditional nvme-stas installation
Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
2024-03-14 09:48:05 +01:00
Olivier Gayot 0ba9dc9ed6
Merge pull request #1931 from Chris-Peterson444/cdrom-metadata
Move metadata collection to Curtin
2024-03-14 09:46:01 +01:00
Chris Peterson 5837eb90f0 model: remove reading /cdrom/.disk/info
Since Curtin now has a builtin hook to copy over information from
/cdrom/.disk, it's uncessary to repeat it in Subiquity.
2024-03-13 12:56:24 -07:00
Chris Peterson 56a785fe02 curtin: bump rev to pickup /cdrom/.disk hook
A new builtin curthook was introduced to address copying over
common metadata from /cdrom/.disk/ at install time. This addressed
copying /cdrom/.disk/info and /cdrom/.disk/ubuntu_dist_channel
(LP: #2037038).
2024-03-13 12:56:20 -07:00
Dan Bungert 7cbe4c9d61
Merge pull request #1934 from dbungert/lp-2051338
filesystem: autoinstall reformat_disk match raids
2024-03-13 12:24:03 -06:00
Dan Bungert 879b393eb5 filesystem: consider raids for has_bitlocker 2024-03-13 11:29:20 -06:00
Dan Bungert c84a94b9f9 filesystem: consider raids for use_gap 2024-03-13 11:29:20 -06:00
Dan Bungert ab7391ee8a filesystem: disk action match fail exception
Move the exception raised by manual storage actions to AutoinstallError
2024-03-13 11:29:20 -06:00
Dan Bungert e6dde2e324 filesystem: basic match logging 2024-03-13 11:29:20 -06:00
Dan Bungert d81bb5e247 filesystem: autoinstall reformat_disk match raids
Raise AutoinstallError on failed match while we're at it, better than
the "disk is None" scenario today.
2024-03-13 11:29:20 -06:00
Dan Bungert c088adf90f
Merge pull request #1935 from ogayot/curtin-systemd-offline
snapcraft: bump curtin revision for the SYSTEMD_OFFLINE handling and deb822 sources
2024-03-13 10:42:15 -06:00
Olivier Gayot 3fd013205f snapcraft: bump curtin revision for the SYSTEMD_OFFLINE handling
Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
2024-03-13 15:57:48 +01:00
Dan Bungert 263520ad0b
Merge pull request #1932 from dbungert/yaaaaaml
quickstart: fix autoinstall indents
2024-03-11 07:14:22 -06:00
Dan Bungert 9111298511 quickstart: fix autoinstall indents 2024-03-09 21:51:39 -07:00
Dan Bungert fdf72cb575
Merge pull request #1928 from dbungert/allow-skip-identity
Allow skip identity
2024-03-08 06:28:30 -07:00
Dan Bungert 7361d22048
Merge pull request #1929 from rkratky/FR-6783_add-ubuntu-image
Add ubuntu-image reference
2024-03-07 18:38:38 -07:00
Dan Bungert 737c3567e1 warn if no users but authorized_keys 2024-03-07 18:24:50 -07:00
Dan Bungert 6626fc2e9c identity: require in autoinstall only on server 2024-03-07 18:24:49 -07:00
Dan Bungert a38c86f085 identity: clarification of user creation handling 2024-03-07 18:24:49 -07:00
Robert Krátký 1b492981b2 Add ubuntu-image reference. 2024-03-07 15:09:47 +01:00
Chris Peterson 8721395803
Merge pull request #1925 from Chris-Peterson444/non-reportable-errors
Support for Non Reportable Errors
2024-03-06 19:54:02 -08:00
Chris Peterson bae102e6cb AutoinstallValidation: Fix typo in error message 2024-03-06 09:09:01 -08:00
Chris Peterson fefd498288 client: Add support for non-reportable errors
Adds support for AutoinstallValidation errors, the first class
of non-reportable errors. Includes a separate error overaly to
display a warning to the user about the issue.

Changes to the server to allow restarting the installer before all
of the controllers are loaded, since the error means the controllers
won't ever be loaded. Adds special handling to the ProgressView to
change the Reboot (the machine) button to a Restart (the installer) button
for this case.
2024-03-06 09:08:56 -08:00
Olivier Gayot 01e4f633ab Merge pull request #1921 from ogayot/nvmeotcp-rootfs
filesystem: accept to place the rootfs on remote storage for NVMe-o-TCP
2024-03-06 14:25:47 +01:00
Olivier Gayot 3bf2c02dfb
Merge pull request #1927 from ogayot/grub-bug-workaround
debconf-selections: work around grub2 bug until it is fixed
2024-03-06 14:21:29 +01:00
Olivier Gayot cffce32305 debconf-selections: work around grub2 bug until it is fixed
Currently, installations of Ubuntu Server and Ubuntu Desktop both fail
on UEFI-based systems because of a grub2 bug. This is a workaround to
avoid failing installs until grub2 migrates to the release pocket.

Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
2024-03-06 13:25:59 +01:00
Olivier Gayot 2670f4857d filesystem: accept to place the rootfs on remote storage for NVMe-o-TCP
Now that curtin more or less supports NVMe over TCP with the rootfs on
remote storage, relax the contraints set by subiquity.

We still need the /boot (and /boot/efi) partitions on local storage
though.

Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
2024-03-06 10:44:07 +01:00
Chris Peterson 30dfc2f0cb server: Define interactivity sooner
Change when the server discovers if the install is interactive or not.
This allows clients to display autoinstall errors in an interactive
way, if applicable. This also enables accessing the ssh_info endpoint
before all of the controllers are loaded. Autoinstall loading happens
after the loading cloudinit stage, so this should be accessible by then.
If a failure happens during/before cloudinit is finished, `interactive`
will still be set to `None` and clients should default to the
non-interactive case.
2024-03-05 11:31:52 -08:00
Chris Peterson 32e7dc54c5 API: Add non-reportable errors to /meta/status API response
Adds a field to the ApplicationStatus struct, nonreportable_error,
to be filled when the server enters an error state due to a
non-reportable error/exception type.
2024-03-05 11:31:52 -08:00
Chris Peterson 1dcb728c12 server: refactor exception handler and make apport suppression generic 2024-03-05 11:31:46 -08:00
Dan Bungert 2fd9c68571
Merge pull request #1926 from dbungert/curtin-namespace-ischroot
snapcraft: rev for ischroot fixes in pid namespace
2024-03-05 11:54:17 -07:00
Dan Bungert abd33a3493 snapcraft: rev for ischroot fixes in pid namespace 2024-03-05 11:40:06 -07:00
Olivier Gayot f06d1956b1
Merge pull request #1924 from ogayot/ssh-ellipsis-fix
ssh: fix UI crash when importing key on non UTF-8 and/or serial terminal
2024-03-05 09:05:24 +01:00
Olivier Gayot 07d7562508 ssh: fix UI crash when importing key on non UTF-8 and/or serial terminal
When importing a key on a terminal with limited capabilities, the UI can
crash with:

 File "urwid/canvas.py", line 1315, in apply_text_layout
     return TextCanvas(t, a, c, maxcol=maxcol)
   File "urwid/canvas.py", line 358, in __init__
     raise CanvasError("Canvas text is wider than the maxcol [...]
 urwid.canvas.CanvasError: Canvas text is wider than the maxcol specified

When a SSH key is too long to be displayed on the terminal, we clip the
end and show the ellipsis "…" character instead. It is supposedly 1
column wide but it reverts to "..." (3 columns wide) on terminals with
limited capabilities.

The bug seems fixed in urwid in noble but we're using core22 for now.
Let's not try to show the character until we switch to core24 (or until
the bug is fixed in jammy).

LP: #2055702

Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
2024-03-04 10:45:52 +01:00
Dan Bungert d010f921d5
Merge pull request #1923 from blackboxsw/cloudinit-no-init-when-disabled
bug(cloudinit): do not call cloudinit stages.Init when disabled
2024-03-01 17:10:43 -07:00
Chad Smith 972e0d55e4 bug(cloudinit): do not call cloudinit stages.Init when disabled
Inspect cloud-init status for disabled. When disabled do not
call stages.Init due to a side-effect that cloud-init tries to
rediscover any viable datasource when none are previously
discovered.

LP: #2055077
2024-03-01 17:03:36 -07:00
Dan Bungert f759d19336
Merge pull request #1922 from dbungert/curtin-zfs-keystore
snapcraft: rev curtin for zfs keystore
2024-02-29 16:04:52 -07:00
Dan Bungert 2f70a4621b snapcraft: rev curtin for zfs keystore 2024-02-29 15:09:31 -07:00
Dan Bungert 0aaade5c53
Merge pull request #1918 from dbungert/use-zfs-keystore
Use zfs keystore
2024-02-27 15:37:19 -07:00
Dan Bungert 922d1bdce0 filesystem: one more ZFS_LUKS->ZFS_LUKS_KEYSTORE 2024-02-27 15:14:34 -07:00
Dan Bungert a8c1143eee filesystem: create zpool with encryption info 2024-02-27 15:14:34 -07:00
Dan Bungert 1b00eb5616 utils: extract write_named_tempfile 2024-02-27 15:14:34 -07:00
Dan Bungert d886dcd97d
Merge pull request #1920 from dbungert/tests-noble
Fix unittests on Noble
2024-02-26 23:58:57 -07:00
Dan Bungert 76c9b6607a console_conf: fix not_called usage 2024-02-26 17:06:17 -07:00
Dan Bungert d266ac6a3f server: fix py3.12 related unittest deprecation 2024-02-26 17:05:53 -07:00
Dan Bungert 6fc7f46dd4
Merge pull request #1917 from dbungert/zfs-luks-keystore
types: rename ZFS_LUKS -> ZFS_LUKS_KEYSTORE
2024-02-23 08:00:03 -07:00
Dan Bungert f60290bb11 types: rename ZFS_LUKS -> ZFS_LUKS_KEYSTORE
Clarify that the implemented mechanism is the keystore setup.  An
implementation that doesn't use native ZFS encryption is plausibly
interesting, which is a better use of the term ZFS_LUKS.
2024-02-23 07:53:27 -07:00
Dan Bungert 98ca9cdfa8
Merge pull request #1919 from bboozzoo/bboozzoo/console-conf-wrapper-sync
bin/console-conf-wrapper: use /run/console-conf, fix mode extraction
2024-02-23 07:17:55 -07:00
Maciej Borzecki 3ea3da1a9a bin/console-conf-wrapper: fix mode extraction when modeenv is not available
We generally expect /var/lib/snapd/modeenv to exist, but in case it does not,
fall back to picking up the mode from kernel command line (just like snapd does
it).

Signed-off-by: Maciej Borzecki <maciej.borzecki@canonical.com>
2024-02-23 14:21:06 +01:00
Maciej Borzecki 09b039a868 bin/console-conf-wrapper: update wrapper to use /run/console-conf
The changes in 66e8222a09 and
f3043cde88 introduced established
/run/console-conf as the project runtime directory. Make sure that the wrapper
uses the same location.

Credits to @kubiko for introducing the changes in his core24 nucleus branch.

Signed-off-by: Maciej Borzecki <maciej.borzecki@canonical.com>
2024-02-23 14:20:48 +01:00