From: Kaiyang Wu <wukaiyang2003@gmail.com>
To: pve-devel@lists.proxmox.com
Cc: Kaiyang Wu <wukaiyang@loongfans.cn>
Subject: [PATCH installer 3/4] tui: show wear-out warning when installing on MMC devices
Date: Fri, 9 Oct 2026 18:52:38 +0800 [thread overview]
Message-ID: <20261009105242.144965-4-wukaiyang@loongfans.cn> (raw)
In-Reply-To: <20261009105242.144965-1-wukaiyang@loongfans.cn>
Signed-off-by: Kaiyang Wu <wukaiyang@loongfans.cn>
---
proxmox-tui-installer/src/main.rs | 25 +++++++++++++++++++++++--
1 file changed, 23 insertions(+), 2 deletions(-)
diff --git a/proxmox-tui-installer/src/main.rs b/proxmox-tui-installer/src/main.rs
index e9f47a9..243457d 100644
--- a/proxmox-tui-installer/src/main.rs
+++ b/proxmox-tui-installer/src/main.rs
@@ -391,10 +391,31 @@ fn bootdisk_dialog(siv: &mut Cursive) -> InstallerView {
match options {
Some(Ok(options)) => {
siv.with_user_data(|state: &mut InstallerState| {
- state.options.bootdisk = options;
+ state.options.bootdisk = options.clone();
});
- switch_to_next_screen(siv, InstallerStep::Timezone, &timezone_dialog);
+ if options
+ .disks
+ .iter()
+ .fold(false, |acc, disk| acc || disk.path.contains("mmcblk"))
+ {
+ siv.add_layer(
+ Dialog::text(
+ "Proxmox VE is write intensive, MMC devices may wear out quickly.",
+ )
+ .title("Warning")
+ .button("Ok", |siv| {
+ siv.pop_layer();
+ switch_to_next_screen(
+ siv,
+ InstallerStep::Timezone,
+ &timezone_dialog,
+ );
+ }),
+ );
+ } else {
+ switch_to_next_screen(siv, InstallerStep::Timezone, &timezone_dialog);
+ }
}
Some(Err(err)) => siv.add_layer(Dialog::info(format!("Invalid values: {err}"))),
--
2.56.0
next prev parent reply other threads:[~2026-10-09 10:53 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-09 10:52 [PATCH installer/proxmox 0/4] add mmcblk device support Kaiyang Wu
2026-10-09 10:52 ` [PATCH installer 1/4] block: add support for MMC devices Kaiyang Wu
2026-10-09 10:52 ` [PATCH installer 2/4] ui: show wear-out warning when installing on " Kaiyang Wu
2026-10-09 10:52 ` Kaiyang Wu [this message]
2026-10-09 10:52 ` [PATCH proxmox 4/4] schema: api-types: add support for " Kaiyang Wu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261009105242.144965-4-wukaiyang@loongfans.cn \
--to=wukaiyang2003@gmail.com \
--cc=pve-devel@lists.proxmox.com \
--cc=wukaiyang@loongfans.cn \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox