Ubuntu Server Installer, and backend for Ubuntu Desktop Installer
Go to file
Olivier Gayot 414a2235e6 storage: fix screen sometimes not refreshing after slow probing
When we reach the storage screens on the installer, if the devices
probing operation has not finished, we:
 * display a temporary "Probing" screen.
 * create an asynchronous task (a.k.a., probing task) that will
   eventually show the "Guide Storage" screen when the probing operation
   finishes.

The probing task checks, when it finishes, that the screen currently
visible is the "Probing" screen. This is the expectation and is true in
most scenarios. But in case a different screen is visible, we skip
refreshing the display.

Unfortunately, sometimes, a "Progress" screen is shown for some time
before the "Probing" screen appears. Consequently, we do not refresh the
screen if the probing operation finishes whilst the Progress screen is
visible.

In order to keep the view returned by make_ui() up-to-date and make sure
that the right screen is shown even if the probing operation finishes
early, we use the level indirection that was implemented in make_ui.

https://bugs.launchpad.net/subiquity/+bug/1968161

Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
2022-04-13 18:34:46 +02:00
.github/workflows workflow: -hirsute 2022-02-03 12:21:04 -07:00
bin do apt configuration before install starts 2021-11-17 12:57:26 +13:00
console_conf Use logger names consistent with directory structure 2022-02-25 17:35:45 +01:00
debian update github urls to new organization 2021-02-23 12:03:37 +13:00
examples Removed systemd from the UI 2022-04-07 10:55:30 +02:00
fake_deps tox: Support running tests and flake8 in tox. 2018-06-05 17:59:46 -04:00
font Add UPPER HALF BLOCK and LOWER HALF BLOCK to subiquity's console font 2019-09-03 12:05:26 +12:00
kbds commit generated file 2021-03-16 16:02:23 +13:00
po remove stdlib backports from Python 3.8 2021-10-12 18:55:09 -06:00
scripts Cleans comments and adresses test. 2022-03-22 19:41:37 -03:00
snap/hooks Revert "os-prober: patch instead of sed" 2022-01-24 12:18:41 -07:00
subiquity storage: fix screen sometimes not refreshing after slow probing 2022-04-13 18:34:46 +02:00
subiquitycore ui: introduce an optional level of indirection in make_ui 2022-04-13 18:34:46 +02:00
system_setup Removed systemd from the UI 2022-04-07 10:55:30 +02:00
.flake8 Make tox and Makefile more similar. 2018-06-05 22:19:17 -04:00
.gitignore .gitignore: ignore .vscode 2021-08-31 15:52:03 +02:00
DESIGN.md expand DESIGN.md a bit 2021-08-05 16:19:13 +12:00
LICENSE Initial commit 2015-06-08 17:57:45 -04:00
Makefile aptdeps: move to external file 2022-03-04 10:49:23 -07:00
README.md Fixed a typo 2021-08-30 12:32:15 +05:30
apt-deps.txt atp-deps.txt: add os-prober 2022-03-14 10:27:05 +01:00
autoinstall-schema.json Rename UbuntuAdvantage -> UbuntuPro but keep autoinstall compat 2022-03-15 11:50:57 +01:00
autoinstall-system-setup-schema.json System-Setup: Add systemd experimental support to WSL 2022-03-16 12:24:18 +01:00
languagelist put a full locale (language/location/codeset) in languagelist 2021-02-12 15:03:10 +13:00
requirements.txt install probert and curtin via Makefile for testing 2021-07-02 13:49:40 +12:00
reserved-usernames do not let the user choose a reserved username 2018-07-17 10:32:48 +12:00
setup.py do apt configuration before install starts 2021-11-17 12:57:26 +13:00
snapcraft.yaml probert: update for 'os' probe_type 2022-03-29 15:09:21 -06:00
tox.ini fix snap build 2018-06-13 13:21:20 +12:00
users-and-groups only add the user to groups that exist in the target system 2018-06-14 15:27:06 +12:00

README.md

subiquity & console-conf

Ubuntu Server Installer & Snappy first boot experience

The repository contains the source for the new server installer (the "subiquity" part, aka "ubiquity for servers") and for the snappy first boot experience (the "console-conf" part).

We track bugs in Launchpad at https://bugs.launchpad.net/subiquity. Snappy first boot issues can also be discussed in the forum at https://forum.snapcraft.io.

Our localization platform is Launchpad, translations are managed at https://translations.launchpad.net/ubuntu/+source/subiquity/

To update translation template in launchpad:

  • update po/POTFILES.in with any new files that contain translations
  • execute clean target, i.e. $ debuild -S
  • dput subiquity into Ubuntu

To export and update translations in subiquity:

Acquire subiquity from source

git clone https://github.com/canonical/subiquity

cd subiquity && make install_deps

Testing out the installer Text-UI (TUI)

Subiquity's text UI is available for testing without actually installing anything to a system or a VM. Subiquity developers make use of this for rapid development. After checking out subiquity you can start it:

make dryrun

All of the features are present in dry-run mode. The installer will emit its backend configuration files to /tmp/subiquity-config-* but it won't attempt to run any installer commands (which would fail without root privileges). Further, subiquity can load other machine profiles in case you want to test out the installer without having access to the machine. A few sample machine profiles are available in the repository at ./examples/ and can be loaded via the MACHINE make variable:

make dryrun MACHINE=examples/simple.json

Generating machine profiles

Machine profiles are generated from the probert tool. To collect a machine profile:

PYTHONPATH=probert ./probert/bin/probert --all > mymachine.json

Testing changes in KVM

To try out your changes for real, it is necessary to install them into an ISO. Rather than building one from scratch, it's much easier to install your version of subiquity into the daily image. Here's how to do this:

  1. Build your change into a snap:

    $ snapcraft snap --output subiquity_test.snap
    
  2. Grab the current version of the installer:

    $ urlbase=http://cdimage.ubuntu.com/ubuntu-server/daily-live/current
    $ isoname=$(distro-info -d)-live-server-$(dpkg --print-architecture).iso
    $ zsync ${urlbase}/${isoname}.zsync
    
  3. Run the provided script to make a copy of the downloaded installer that has your version of subiquity:

    $ sudo ./scripts/inject-subiquity-snap.sh ${isoname} subiquity_test.snap custom.iso
    
  4. Boot the new iso in KVM:

    $ qemu-img create -f raw target.img 10G
    $ kvm -m 1024 -boot d -cdrom custom.iso -hda target.img -serial stdio
    
  5. Finally, boot the installed image:

    $ kvm -m 1024 -hda target.img -serial stdio
    

The first three steps are bundled into the script ./scripts/test-this-branch.sh.