Commit Graph

979 Commits

Author SHA1 Message Date
Thomas Lamprecht
0903eb5cf8 UI: add and use display_html helper
This is used often, among other things also for some abort code, so
move the essence to the UI.

Allows to drop one global variable for proxinstall, which is a nice
side effect.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 21:49:00 +02:00
Thomas Lamprecht
5c6ca00a12 UI: add ISO env on setup
can be useful for UI's to get resources or the like

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 21:49:00 +02:00
Thomas Lamprecht
72bea99528 switch prompt, error and message calls to new UI infra
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 21:49:00 +02:00
Thomas Lamprecht
5f031868a5 proxinstall: wire up UI module
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 21:49:00 +02:00
Thomas Lamprecht
bc05a8fc6b add basic UI plugin infrastructure
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 21:49:00 +02:00
Christoph Heiss
170ab052a1 tui: limit FloatEditView to 2 decimal places
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
2023-06-19 15:09:53 +02:00
Christoph Heiss
d4d0f2bfee tui: error out if no harddisks were detected
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
2023-06-19 15:09:53 +02:00
Christoph Heiss
706cdb2afd tui: round disk sizes when displaying
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 15:08:03 +02:00
Christoph Heiss
beec6a1754 tui: drop now-obsolete cargo config
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 15:08:03 +02:00
Wolfgang Bumiller
b5aa2ddfe3 tui: use network info
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 15:08:03 +02:00
Thomas Lamprecht
0889f35dcf buildsys: add prerequisites to compiled binaries target
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 15:08:03 +02:00
Thomas Lamprecht
63ce0b1a09 buildsys: avoid copying over build dir and debs on test-deb target
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 15:08:03 +02:00
Thomas Lamprecht
0190a2994a buildsys: add DSC & sbuild convenience target
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 15:08:03 +02:00
Thomas Lamprecht
59597871f7 buildsys: use better defined clean target
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 15:08:03 +02:00
Thomas Lamprecht
2d5382e86a buildsys: expand clean target
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 15:08:03 +02:00
Thomas Lamprecht
67e0a9503c d/control: use misc:Depends and shlibs:Depends dh variables
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 15:08:03 +02:00
Thomas Lamprecht
99f0b52331 makefile: convert to use simple parenthesis
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 14:18:14 +02:00
Christoph Heiss
f7bd21a637 tui: left-align cell values in summary view
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
2023-06-19 13:39:31 +02:00
Christoph Heiss
25e0af5812 tui: calculate default swap size for LVM installs based on system memory
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
2023-06-19 13:39:31 +02:00
Christoph Heiss
80f54e90ae tui: fix minimum free LVM space default
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
2023-06-19 13:39:31 +02:00
Christoph Heiss
429718b894 tui: add option to leave some disks unselected in RAID setups
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
2023-06-19 13:39:31 +02:00
Christoph Heiss
d85180edf3 tui: rename raid levels 0/1 to align with GUI installer
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
2023-06-19 13:39:31 +02:00
Christoph Heiss
4f2295a739 tui: simplify installer data path construction
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
2023-06-19 13:39:31 +02:00
Thomas Lamprecht
0cf4be7de4 buildsys: add check-pve-tui target
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 13:38:56 +02:00
Wolfgang Bumiller
2473d5dc2e tui: load runtime info, use disks
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2023-06-19 13:27:53 +02:00
Wolfgang Bumiller
066b9360ac tui: add runtime info serde structure
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2023-06-19 13:27:53 +02:00
Wolfgang Bumiller
1c5e103adf move dns into network section in runtime info
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2023-06-19 13:27:53 +02:00
Thomas Lamprecht
57feade1a6 low-level: drop outdated comment
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:40:03 +02:00
Thomas Lamprecht
db97dbacaf low-level: dump runtime enviroment
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:38:14 +02:00
Thomas Lamprecht
92c7b5c916 low level installer: init a per-command log
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:20:38 +02:00
Thomas Lamprecht
1118bc49c9 buildsys: install RunEnv module
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Thomas Lamprecht
0d27321b79 run env: do not export non-existing is_test_mode method
Probably left over from using ISOEnv as base

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Wolfgang Bumiller
37545cce04 RunEnv: exclude zfs in query_blockdevs
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Wolfgang Bumiller
2231d22680 add Proxmox::Install::RunEnv module
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Thomas Lamprecht
6ec8d1636a use separate faster and incremental DEB build for check targets
Faster as lintian isn't called on the resulting package and
incremental, as the no-pre-clean (-nc) flag is passed to build
package.

This is mostly relevant since the rust based TUI prototype got added
to packaging, as those needs quite a bit longer compared to copying
perl module files.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Thomas Lamprecht
aee9344c83 package rust based TUI installer prototype
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Thomas Lamprecht
9cdfeefcb1 buildsys: use full DEB_VERSION
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Thomas Lamprecht
4368b6dc51 debian: wrap-and-sort -tkn
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Thomas Lamprecht
4213602716 add top-level cargo wrokspace
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Thomas Lamprecht
00104045a1 tui: build with sources from debian pacakges
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2023-06-19 12:19:37 +02:00
Maximiliano Sandoval
ddc887bce5 stop main loop when closing the main window
Without this change closing the main window does not exit the main loop.

Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
2023-06-19 09:34:55 +02:00
Maximiliano Sandoval
fd09e89311 exit process gracefully
We make sure that all exit calls quit the Glib main loop and child
processes.

Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
2023-06-19 09:34:17 +02:00
Maximiliano Sandoval
f9bc57c4c2 stop using Gtk3::Window->set_has_resize_grip
The property GtkWindow::has-resize-grip was deprecated in GTK 3.14,
instead we make the window unresizable.

Note that we set the value of resizable only after the window has been
mapped and knows how much space it needs, also note that this only works
correctly if the window is properly displayed via present.

Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
2023-06-19 09:30:51 +02:00
Maximiliano Sandoval
bbf5122557 stop using Gtk3::HSeparator
This was deprecated in GTK 3.2, the replacement Gtk3::Separator was
added in GTK 3.0.

Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
2023-06-19 09:30:51 +02:00
Maximiliano Sandoval
d6efed199c stop using Gtk3::HBox and Gtk3::VBox
These widgets were deprecated in GTK 3.2 and replaced by Gtk3::Box which
was introduced in 3.0.

The packing changes require to horizontally expand the WebKit2::WebView
widget.

Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
2023-06-19 09:30:51 +02:00
Maximiliano Sandoval
9f91507bae stop using Gtk3::Misc->set_alignment
This was deprecated in GTK 3.14, instead we use
GtkLabel:{xalign,yalign}. Note that by default they are both set to 0.5.

Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
2023-06-19 09:30:51 +02:00
Wolfgang Bumiller
282ea9c559 tui: no need to have './' fallible
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2023-06-16 13:32:54 +02:00
Wolfgang Bumiller
03888174fb tui: only count exact example email address as invalid
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2023-06-16 13:32:54 +02:00
Wolfgang Bumiller
32368ac302 tui: properly group imports
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2023-06-16 13:32:54 +02:00
Wolfgang Bumiller
52f80858e6 tui: dependencies: group our own crates separately
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
2023-06-16 13:32:54 +02:00