Summary
Two gaps in LXC mount-point handling in fog-proxmox:
- Mount options dropped on read.
Fog::Proxmox::Compute::Disk (lib/fog/proxmox/compute/models/disk.rb) declares only a subset of mount options, and ServerConfig#initialize_disks extracts declared attributes only. So ro, mountoptions, acl, quota are parsed away when reading a container config — they can be written via pass-through but do not round-trip on edit. (replicate/shared are declared and do round-trip.)
- Bind mounts not representable.
DiskHelper.extract_storage_volid_size (lib/fog/proxmox/helpers/disk_helper.rb) assumes a storage:size / volid volume; a host-path bind mount (mp0: /host/dir,mp=/ct/dir,size=0) starts with / and the regex can't parse it, so bind mounts can't be modelled.
Proposed change
- Add
ro, mountoptions, acl, quota as attributes on Disk.
- Support a bind-mount / host-directory volume (leading
/, size=0) in DiskHelper.
Context
Needed by foreman_fog_proxmox to expose complete LXC mount-point options and bind mounts.
Drafted with the assistance of Claude (Cowork); reviewed by me before submitting.
Summary
Two gaps in LXC mount-point handling in fog-proxmox:
Fog::Proxmox::Compute::Disk(lib/fog/proxmox/compute/models/disk.rb) declares only a subset of mount options, andServerConfig#initialize_disksextracts declared attributes only. Soro,mountoptions,acl,quotaare parsed away when reading a container config — they can be written via pass-through but do not round-trip on edit. (replicate/sharedare declared and do round-trip.)DiskHelper.extract_storage_volid_size(lib/fog/proxmox/helpers/disk_helper.rb) assumes astorage:size/ volid volume; a host-path bind mount (mp0: /host/dir,mp=/ct/dir,size=0) starts with/and the regex can't parse it, so bind mounts can't be modelled.Proposed change
ro,mountoptions,acl,quotaas attributes onDisk./,size=0) inDiskHelper.Context
Needed by foreman_fog_proxmox to expose complete LXC mount-point options and bind mounts.
Drafted with the assistance of Claude (Cowork); reviewed by me before submitting.