mount: prefer boot disk ESP and run cargo fmt
* choose ESP matching the primary data disk when multiple ESPs exist, falling back gracefully for single-disk layouts * keep new helper to normalize device names and reuse the idempotent mount logic * apply cargo fmt across the tree
This commit is contained in:
14
src/types.rs
14
src/types.rs
@@ -15,15 +15,15 @@
|
||||
// - Keep field names and enums stable; update docs/SCHEMA.md when public surface changes.
|
||||
// REGION: RESPONSIBILITIES-END
|
||||
|
||||
use serde::{Deserialize, Serialize};
|
||||
use clap::ValueEnum;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
pub struct LoggingConfig {
|
||||
/// Log level: "error" | "warn" | "info" | "debug"
|
||||
pub level: String, // default "info"
|
||||
pub level: String, // default "info"
|
||||
/// When true, also log to /run/zosstorage/zosstorage.log
|
||||
pub to_file: bool, // default false
|
||||
pub to_file: bool, // default false
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||
@@ -55,7 +55,11 @@ pub enum Topology {
|
||||
#[value(alias = "ssd-hdd-bcachefs")]
|
||||
SsdHddBcachefs,
|
||||
/// Multi-device bcachefs with two replicas (data+metadata).
|
||||
#[value(alias = "bcachefs2-copy", alias = "bcachefs-2copy", alias = "bcachefs-2-copy")]
|
||||
#[value(
|
||||
alias = "bcachefs2-copy",
|
||||
alias = "bcachefs-2copy",
|
||||
alias = "bcachefs-2-copy"
|
||||
)]
|
||||
Bcachefs2Copy,
|
||||
/// Optional mirrored btrfs across two disks when explicitly requested.
|
||||
#[value(alias = "btrfs-raid1")]
|
||||
@@ -205,4 +209,4 @@ pub struct Config {
|
||||
pub mount: MountScheme,
|
||||
/// Report output configuration.
|
||||
pub report: ReportOptions,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user