Introduce a new view, model and controllers pair to enable Ubuntu
Advantage from Subiquity. For now, we expect the user to input an
alphanumeric token and rely on cloud-init to enable the features
associated with the subscription.
This implementation comes with a number of limitations:
* inability to validate the token before first-boot
* inability to check what features are associated with the Ubuntu
Advantage subscription, before first-boot
* the user must input the token directly: there is no mechanism to
deduce the token based on email address and password.
The new screen is placed after the identity scree. The installation
should already be running when the UA screen will be shown to the user.
Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
Read ID_MODEL/VENDOR_ENC for disks to allow the GUI installer to show
pretty disk names without having to call libudev through FFI.
As a bonus, this also fixes disk names to match the machine config in
dry-run mode.
Related issues
- FR-1710
- canonical/ubuntu-desktop-installer#415
When comparing version numbers (i.e., to determine if we want to suggest
and upgrade of subiquity) we now support version numbers of the
following form:
{major}.{minor}.{patch}+git{build_id}.{commit_id}
The commit ID is ignored in the resolution because it is not a number
that is growing.
Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
In specific scenarios, the version of the snap as returned by snapd is
older than the version currently running. When that happens, we were
suggesting the user to update. This action would effectively result in a
downgrade.
We now attempt to determine if the snapd version is greater than the one
currently running. If we can't the behavior is unaffected.
Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
The python links in the bin dir of the snap were resolving to system
python instead of the python binary found at usr/bin. This appears to
be the root cause of why python scripts would fail to find their own
resources, such as ssh-import-id and lsb_release.
The check-language-support on my machine was providing a single empty
newline as output, and the length check isn't catching that as the
resulting packages array has a value of [''].
Drop empty values from the list to avoid a "KeyError: ''" exception.