[pve-devel] storage plugins: what is plugindata()->{content}[1]

Fabian Grünbichler f.gruenbichler at proxmox.com
Fri Feb 7 10:18:42 CET 2025


> Roland Kammerer via pve-devel <pve-devel at lists.proxmox.com> hat am 07.02.2025 10:02 CET geschrieben:
> Hi all,
> 
> rather simple question I guess, but I could not find the answer in
> https://pve.proxmox.com/wiki/Storage_Plugin_Development and linked
> documents and looks like my grep foo is lacking today, so here we go:
> I guess I know what the first hash in the 'content' array is, but what
> is the second? Actually, why is there a second one?
> 
> Storage/LVMPlugin.pm:
> content => [ {images => 1, rootdir => 1}, { images => 1 }]
> 
> vs.
> 
> Storage/LvmThinPlugin.pm:
> content => [ {images => 1, rootdir => 1}, { images => 1, rootdir => 1}]
> 
> Best, rck

the first one defines the allowed/valid content types, the second the default one(s):

https://git.proxmox.com/?p=pve-storage.git;a=blob;f=src/PVE/Storage/Plugin.pm;h=65cf43f7fa32860f709fd8a4568f0ff346dc3d12;hb=HEAD#l544

we are working on improving the docs and cleaning all of this up!

Fabian




More information about the pve-devel mailing list