feat(onboarding): add dedicated boot pool option to internal boot wizard#1968
feat(onboarding): add dedicated boot pool option to internal boot wizard#1968elibosley merged 5 commits intoclaude/bold-gaussfrom
Conversation
- Previously, the internal boot wizard only offered a "hybrid" mode where
the device serves as both a boot volume and a data storage pool
- Users who want a clean separation of boot and data had no option
- Add a "Pool mode" dropdown as the first field in the storage boot
configuration form with two options:
- "Dedicated boot pool": uses the entire device exclusively for booting
Unraid (passes poolBootSize=0 to emcmd), hides pool name and boot
reserved size fields, auto-sets pool name to "boot"
- "Boot + data pool": preserves the existing hybrid behavior with all
fields visible for user configuration
- Update UAlert info panels to show mode-specific descriptions:
- Dedicated mode explains that no data pool is created and notes that
in a 2-device mirror, boot partition size equals the smallest device
- Hybrid mode retains all existing text about two volumes
- Update validation logic in buildValidatedSelection() to skip pool name
format and boot size validation for dedicated mode, while still checking
for reserved name conflicts on the auto-set "boot" pool name
- Add poolMode field to OnboardingInternalBootSelection interface and
draft store with backward-compatible normalization (defaults to 'hybrid'
for existing persisted data from localStorage)
- Update summary step to show pool mode and conditionally hide pool name
and boot reserved size rows for dedicated mode
- Add 10 new i18n keys for pool mode labels, descriptions, and validation
- Update all existing test files to include poolMode in selection objects
- No backend changes needed: bootSizeMiB=0 is already valid per @min(0)
validation and cmdMakeBootable already handles poolBootSize=0 as the
"use entire pool" sentinel value
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@coderabbitai review |
✅ Actions performedReview triggered.
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## claude/bold-gauss #1968 +/- ##
=====================================================
+ Coverage 52.08% 52.11% +0.03%
=====================================================
Files 1031 1031
Lines 71461 71586 +125
Branches 8094 8102 +8
=====================================================
+ Hits 37222 37310 +88
- Misses 34114 34151 +37
Partials 125 125 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
…uping
- Add pool mode title ("Dedicated boot pool" / "Boot + data pool") as
the first line in each info UAlert so users immediately know which
mode's description they're reading
- Swap text order in dedicated mode UAlert: mirror description now comes
before the mirror size note, which reads more naturally (explain the
feature, then the detail)
- Reorganize form fields into two logical sections:
- "Pool Settings": Pool mode dropdown + Data pool name input (hidden
in dedicated mode)
- "Devices": Boot devices count + device selection dropdowns + boot
reserved size (hidden in dedicated mode)
- Rename "Pool name" label to "Data pool name" for clarity in hybrid mode
- Add section header i18n keys for "Pool Settings" and "Devices"
- Change "Each bootable pool contains two volumes:" to "Each device contains two volumes:" for clearer language that focuses on the physical device rather than the pool abstraction
- When switching from dedicated to hybrid mode, the pool name ref retained the value "boot" which would incorrectly prepopulate the data pool name input - Add a watcher on poolMode that resets poolName to the appropriate default when switching: "boot" for dedicated, the template default (typically "cache") for hybrid — but only if the current value is still "boot" to avoid overwriting a user-entered name
…ists - The poolMode watcher used `?? 'cache'` as fallback, but poolNameDefault is '' (empty string) when pools already exist, and ?? doesn't catch empty strings — so it would incorrectly default to 'cache' even when a cache pool was already present - Change fallback to '' so the user gets an empty field and must choose their own name, matching the existing behavior
|
This plugin has been deployed to Cloudflare R2 and is available for testing. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d06d533a44
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (reservedNames.value.has(normalizedPoolName) || existingPoolNames.value.has(normalizedPoolName)) { | ||
| formError.value = t('onboarding.internalBootStep.validation.dedicatedPoolNameConflict'); |
There was a problem hiding this comment.
Skip reserved-name rejection for dedicated boot mode
In dedicated mode the pool name is forced to boot, but this branch still rejects it when reservedNames contains that value. The internal boot context currently forwards vars.reservedNames directly from emhttp, and those payloads commonly include boot; in that environment this validation path always raises dedicatedPoolNameConflict, so users can never complete the new dedicated flow.
Useful? React with 👍 / 👎.
Summary
Adds a dedicated boot pool option to the onboarding internal boot wizard, giving users the choice between:
Problem
Previously, the internal boot wizard only offered the hybrid "boot + data pool" mode. Users who want a clean separation of boot and data devices — dedicating one device entirely to boot and managing data pools separately — had no way to do this through the onboarding wizard.
Solution
A new "Pool mode" dropdown is added as the first field in the storage boot configuration form. When "Dedicated boot pool" is selected:
poolBootSize=0is passed tocmdMakeBootablevia emcmd, which tells the backend to use the entire device for the boot partition"boot"(hidden from the user)When "Boot + data pool" is selected, the existing behavior is fully preserved — all fields remain visible and the user configures pool name and boot size as before.
Key Design Decisions
bootSizeMiB: 0is already valid per the existing@Min(0)validation onCreateInternalBootPoolInput, andcmdMakeBootablealready handlespoolBootSize=0as the "use entire pool" sentinel value"boot"name conflicts with an existing pool or reserved name, a clear validation error is shown rather than using a fallback name chainpoolModefield in the persisted draft store defaults to'hybrid'when missing, so existing localStorage data from prior sessions works without issuesChanges
Source Files
web/src/components/Onboarding/store/onboardingDraft.tsOnboardingPoolModetype andpoolModefield toOnboardingInternalBootSelection, backward-compatible normalizationweb/src/components/Onboarding/composables/internalBoot.tsPoolModetype andpoolModetoInternalBootSelectioninterfaceweb/src/components/Onboarding/steps/OnboardingInternalBootStep.vueweb/src/components/Onboarding/steps/OnboardingSummaryStep.vueweb/src/locales/en.jsonTest Files
web/__test__/components/Onboarding/internalBoot.test.tspoolModeto all selection objectsweb/__test__/components/Onboarding/OnboardingInternalBootStep.test.tsweb/__test__/components/Onboarding/OnboardingInternalBootStandalone.test.tspoolModeto type, selection objects, and assertionweb/__test__/components/Onboarding/OnboardingSummaryStep.test.tspoolModeto inline type and all selection objectsweb/__test__/components/Onboarding/OnboardingNextStepsStep.test.tspoolModeto inline type and all selection objectsData Flow
Test Plan
bootSizeMiB: 0Stacked On
This PR is stacked on
claude/bold-gaussand should be merged after that branch lands.