v0.24.0 — Pre-testing observability: debug logging, diagnostic dump, startup self-test
- Add [DEBUG] logging across all modules (backup, storage, sync, selfupdate, monitor, notify, report, assets, setup) gated behind logging.level: "debug" - Add /api/debug/dump endpoint returning full controller state JSON (debug only) - Add startup self-test validating 9 subsystems (Docker, dirs, storage, hub, restic repos, metrics DB) with pass/warn/fail summary - New packages: internal/selftest, internal/util - Constructor/signature changes: debug bool params, logger params on RunHealthCheck and BuildReport, smart watchdog probe logging Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -3,16 +3,19 @@ package storage
|
||||
import (
|
||||
"bufio"
|
||||
"fmt"
|
||||
"log"
|
||||
"strings"
|
||||
)
|
||||
|
||||
// FormatRequest holds parameters for formatting and mounting a disk.
|
||||
type FormatRequest struct {
|
||||
DevicePath string // "/dev/sdb" or "/dev/sdb1"
|
||||
MountName string // "hdd_1" → mounts at /mnt/hdd_1
|
||||
Label string // Display label for the UI
|
||||
CreatePartition bool // If true, create a single partition first (wipes disk)
|
||||
SetDefault bool // Register as default storage path
|
||||
DevicePath string // "/dev/sdb" or "/dev/sdb1"
|
||||
MountName string // "hdd_1" → mounts at /mnt/hdd_1
|
||||
Label string // Display label for the UI
|
||||
CreatePartition bool // If true, create a single partition first (wipes disk)
|
||||
SetDefault bool // Register as default storage path
|
||||
Logger *log.Logger // Optional logger for debug output
|
||||
Debug bool // Enable debug logging
|
||||
}
|
||||
|
||||
// FormatProgress tracks the formatting/mounting progress.
|
||||
|
||||
Reference in New Issue
Block a user