diff --git a/controller/README.md b/controller/README.md index 4b598bc..fdca48c 100644 --- a/controller/README.md +++ b/controller/README.md @@ -378,6 +378,24 @@ A step-by-step UI at `/settings/storage/init`: Safety guards: system disk detection, mount path conflict check, confirmation required, progress channel for real-time UI feedback. +#### Attach Existing Drive Wizard (`internal/storage/attach.go`) + +A step-by-step UI at `/settings/storage/attach` for drives that already have a filesystem (e.g., a previously used ext4 drive). Unlike the init wizard, this does **not** format the drive — existing data is preserved. + +**Problem solved:** Mounting a whole drive at `/mnt/` would mix existing user data with the controller's directory structure (`storage/`, `Dokumentumok/`, backup repos). The bind-mount approach isolates the controller's working directory from other data on the drive. + +1. **Scan** — Lists available disks, filtered to partitions that have an existing filesystem (FSType != "") +2. **Mount raw** — Partition is mounted read-only at a hidden staging path (`/mnt/.felhom-raw/