feat(pi): mount USB drives in Files without auto data-disk migration#2149
Open
LuckyCoders wants to merge 2 commits into
Open
feat(pi): mount USB drives in Files without auto data-disk migration#2149LuckyCoders wants to merge 2 commits into
LuckyCoders wants to merge 2 commits into
Conversation
The Pi external storage mount script silently ran wipefs and mkfs.ext4 when a single USB disk was not recognised as an Umbrel data drive. Require explicit opt-in before formatting and block foreign filesystems. Fixes getumbrel#1956 Co-authored-by: Cursor <cursoragent@cursor.com>
Skip the Pi boot data-disk script unless umbrel-allow-external-format is set. Enable umbreld external storage on Raspberry Pi, install ntfs-3g on arm64, and exclude disks already used as the Umbrel data volume at /mnt/data. Depends on fix/pi-refuse-auto-format-external-usb Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Raspberry Pi currently uses a boot-time script (
umbrel-external-storage) that treats any single USB disk as a Umbrel data disk (wipe +mkfs.ext4 -L umbrel). The Files app external storage feature is disabled on Pi in both backend and UI.This PR separates the two flows:
umbreldunder Files → External, like on Umbrel Home / x86.umbrel-allow-external-formatexists on the SD card boot partition (same flag as the format-safety PR).Fixes the common case where users plug in a drive with existing data (NTFS/exFAT/ext4) expecting removable storage, not a wiped Umbrel data volume.
Depends on: #2148 (fix/pi-refuse-auto-format-external-usb)
Problem
On Pi, connecting a USB drive could trigger:
wipefs+ GPT +mkfs.ext4 -L umbrel(if not ext4 / no.umbrel)Changes
Boot script (
umbrel-external-storage)umbrel-allow-external-formatis not present/home/umbrel) only runs with explicit opt-inumbreldexternal storagesupported()→true)/mnt/data(Umbrel data volume) from/Externalfiles.isExternalStorageSupportedUI
files.isExternalStorageSupportedinstead of hardcodedproductName !== 'Raspberry Pi'OS image
ntfs-3gon arm64 (was amd64-only)