v0.59.0: report backing device + capacity for a registry-sourced /disks row
Agent-view showed "—" device + no size for a raw (no-PVE-storage) drive because the registry union row never set backing_device/total_bytes/used_bytes (Observe drives get those from pvesm status). Resolve BackingDevice via ByUUIDDevicePath + read capacity via statfsCapacity (build-tagged syscall.Statfs; no-op off-Linux). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
//go:build !linux
|
||||
|
||||
package localapi
|
||||
|
||||
// statfsCapacity is Linux-only (syscall.Statfs); on other platforms (dev builds) it reports nothing.
|
||||
func statfsCapacity(string) (total, used int64, ok bool) { return 0, 0, false }
|
||||
Reference in New Issue
Block a user