Commit Graph

2553 Commits

Author SHA1 Message Date
Dimitri John Ledkov bd9deda177
Merge pull request #426 from xnox/zdev
Basic zdev view
2019-06-10 15:49:39 +01:00
Dimitri John Ledkov be3934792f
Merge pull request #501 from xnox/left-align-fs
Left align filesystems layout page.
2019-06-06 16:30:26 +01:00
Dimitri John Ledkov dac6f12c0f Basic zdev view 2019-06-06 16:15:15 +01:00
Dimitri John Ledkov 8d5982cabe Left align filesystems layout page. 2019-06-06 14:40:04 +01:00
Michael Hudson-Doyle c1e3ad98b3 fixup! call extract_storage_config with probert config to create actions 2019-05-31 15:07:53 +12:00
Michael Hudson-Doyle 245d562f68 fixup! the REFORMAT action 2019-05-31 15:07:53 +12:00
Michael Hudson-Doyle 8cf5bacfbb fixup! support for editing existing partitions 2019-05-31 15:07:53 +12:00
Dimitri John Ledkov f9a7a7c3e4 Merge remote-tracking branch 'origin/pull/495/head' 2019-05-30 15:47:50 +01:00
Michael Hudson-Doyle 6fb185647b tweak _Device.available for existing partitions 2019-05-30 15:39:16 +12:00
Michael Hudson-Doyle 9ef3ce19a1 add ppa:mwhudson/devirt to get newer version of curtin for now 2019-05-30 15:38:09 +12:00
Michael Hudson-Doyle 880d23cb75 use my curtin branch for now 2019-05-30 15:38:09 +12:00
Michael Hudson-Doyle 118a11cfa6 remove old sample machine data 2019-05-30 15:38:09 +12:00
Michael Hudson-Doyle 8c7dbb21f4 log block discovery stuff in separate directory
so we can tell people to send us /var/log/installer/block when odd
things happen.
2019-05-30 15:38:03 +12:00
Michael Hudson-Doyle 0c55149c31 run integration tests with simple sample data 2019-05-30 15:33:59 +12:00
Michael Hudson-Doyle f188a4a4b0 clear disk.preserve when needed
also never set disk.wipe: setting preserve=False/ptable=gpt is
equivalent anyay.
2019-05-30 15:33:59 +12:00
Michael Hudson-Doyle c99227a310 support for reusing an existing swap partition
the showing and hiding of fields is fairly horrible, but not *too*
horrible.
2019-05-30 15:33:59 +12:00
Michael Hudson-Doyle aef842a11f allow the user to choose whether to reformat the ESP 2019-05-30 15:33:59 +12:00
Michael Hudson-Doyle 83574fbc0b mark formatted existing partions as ok_for_{raid,lvm_vg}
as we do not support removing an exisiting format, this is required to
be able to reuse these partitions!
2019-05-30 15:33:59 +12:00
Michael Hudson-Doyle e63204afa9 mounting a partition of a disk that can be the boot disk makes it the boot disk 2019-05-30 15:33:59 +12:00
Michael Hudson-Doyle 52ee6cdde1 use reformat instead of reset in guided disk selection 2019-05-30 15:33:59 +12:00
Michael Hudson-Doyle 97952ef9be adapt make_boot_disk for existing boot partitions 2019-05-30 15:33:59 +12:00
Michael Hudson-Doyle 2f844d09d3 the REFORMAT action 2019-05-30 15:33:59 +12:00
Michael Hudson-Doyle 4c3a46669b fix up enabling of actions in face of preexisting things 2019-05-30 15:33:55 +12:00
Michael Hudson-Doyle 4b45d02f73 adjust usage labels 2019-05-30 15:10:54 +12:00
Michael Hudson-Doyle f3ffd9b8e9 add new/existing annotations 2019-05-30 15:10:54 +12:00
Michael Hudson-Doyle 628758811e support for editing existing partitions 2019-05-30 15:10:54 +12:00
Michael Hudson-Doyle 620d7b1973 call extract_storage_config with probert config to create actions 2019-05-30 15:10:54 +12:00
Michael Hudson-Doyle e6ace190e3 add existing partitions sample data 2019-05-30 15:10:54 +12:00
Michael Hudson-Doyle 35b16acee1 display information about partitions in delete confirmation
For a while subiquity only allowed you to delete RAIDs/VGs with no
partitions. Now that we do, include information about the doomed
partitions in the confirmation dialog.
2019-05-30 15:10:34 +12:00
Michael Hudson-Doyle 97d5248aef summarize disk usage in the guided disk selection view 2019-05-30 15:10:34 +12:00
Michael Hudson-Doyle 4db967766b factor some of device summarization out into a separate function 2019-05-30 15:10:34 +12:00
Michael Hudson-Doyle d48e33ae36 Display all info about a partition on a single line in filesystem view
And add a space between each device.
2019-05-30 15:10:34 +12:00
Michael Hudson-Doyle 3bdca52ed4 Tweak the adjustment of table columns widths for cells with colspan > 1
When allocating space for a cell colspan > 1, preferentially
allocate space to columns that have no colspan = 1 cells. If you
have content like this (content padded to 10 and 20 chars to make
calculations easier):

[[(2, "longer content567890"), "shorter890"],
 ["shorter890", (2, "longer content567890")]]

Taking only colspan = 1 cells into account, the widths of the
columns are (10, 0, 10).

To fit the first longer content in, the current algorithm expands
the first two columns equally, so the widths become (15, 5, 10).

Then to fit the second longer content in, the second two columns
are widened equally (or nearly so), resulting in final widths
of (15, 8, 12) and a table layout like this:

    +-------------------------+--------------+
    | longer content567890    | shorter890   |
    +-----------------+-------+--------------+
    | shorter890      | longer content567890 |
    +-----------------+----------------------+

which is bizarrely asymmetrical given the input and wider than it
needs to be.

If instead we preferentially widen columns that have no width
from colspan = 1 columns, we get this layout:

    +----------------------+------------+
    | longer content567890 | shorter890 |
    +------------+---------+------------+
    | shorter890 | longer content567890 |
    +------------+----------------------+

Which is much more in line with my expectations.
2019-05-30 15:10:34 +12:00
Michael Hudson-Doyle 3bad9e408a move "usage labels" from filesystem view to model objects
So the logic can be reused.
2019-05-30 15:10:34 +12:00
Michael Hudson-Doyle f45880944e create partitions for testing directly
FilesystemModel.add_partition does a bit too much stuff
2019-05-30 15:09:40 +12:00
Michael Hudson-Doyle c659c08d2e fix TestFilesystemModel.assertActionPossible 2019-05-30 14:52:06 +12:00
Michael Hudson-Doyle aad19ecf22
Merge pull request #499 from mwhudson/ok_for_xxx-tests
add tests for ok_for_raid/ok_for_lvm_vg
2019-05-30 11:23:50 +12:00
Michael Hudson-Doyle ef12e1343e add tests for ok_for_raid/ok_for_lvm_vg
also make the various implementations more consistent.
2019-05-30 11:18:00 +12:00
Michael Hudson-Doyle a4d44ba7a8
Merge pull request #498 from mwhudson/validate-raid-lvm-answers
when assembling vg from answers, check devices are ok_for_lvm_vg
2019-05-30 10:23:58 +12:00
Michael Hudson-Doyle 4a22f22189 when assembling vg from answers, check devices are ok_for_lvm_vg
And similar for RAID. Fix a couple of the answers files that got this
wrong and only worked by chance.
2019-05-30 10:07:26 +12:00
Michael Hudson-Doyle 9bd9ecb1a2
Merge pull request #497 from mwhudson/make_boot_disk-tests
add some tests for FilesystemController.make_boot_disk
2019-05-29 16:11:04 +12:00
Michael Hudson-Doyle a32b625404 add some tests for FilesystemController.make_boot_disk 2019-05-29 15:39:15 +12:00
Michael Hudson-Doyle 041ed1fadf
Merge pull request #496 from mwhudson/device-action-tests
add a tonne of tests for when various device actions are permitted
2019-05-29 11:41:52 +12:00
Michael Hudson-Doyle 3701438aa9 add a tonne of tests for when various device actions are permitted
Fix a bug on ppc64el this found.
2019-05-29 11:36:14 +12:00
Michael Hudson-Doyle 849b5f12f1
Merge pull request #494 from mwhudson/fs-actions-once
only run filesystem actions from answers once
2019-05-28 11:38:14 +12:00
Michael Hudson-Doyle c1c9f0e174 only run filesystem actions from answers once
This means you can use an answers file that leaves you on the filesystem
screen, click "back" to choose a different option and not have
everything fall over in a heap.
2019-05-28 10:57:50 +12:00
Michael Hudson-Doyle 96a235f919
Merge pull request #493 from mwhudson/lv-available
a mounted lv should not be considered to be available
2019-05-28 10:34:32 +12:00
Michael Hudson-Doyle 85a7668926 a mounted lv should not be considered to be available 2019-05-28 10:26:25 +12:00
Michael Hudson-Doyle fd7a56a8b5
Merge pull request #492 from mwhudson/fsmodel-tweaks
filesystem model tweaks
2019-05-24 09:21:53 +12:00
Michael Hudson-Doyle 2d145beaa8 add explicit marking of action reverse dependencies
I.e. reverse_depends(disk) yields the partitions.
2019-05-23 15:06:07 +12:00