Resource: proxmox_storage_rbd¶
Warning
Experimental. Schema and behavior may change in future releases. Pin the provider version if stability matters.
Manages an RBD storage on the Proxmox VE cluster's own Ceph cluster, for example on a pool managed by proxmox_ceph_pool. Storages on external Ceph clusters aren't supported yet.
Example Usage¶
resource "proxmox_ceph_pool" "vm" {
node_name = "pve"
name = "vm"
application = "rbd"
size = 3
min_size = 2
}
resource "proxmox_storage_rbd" "example" {
id = "ceph-vm"
pool = proxmox_ceph_pool.vm.name
content = ["images", "rootdir"]
krbd = true
}
# A storage on an erasure-coded pool keeps image metadata in the metadata pool and image data in the data pool.
resource "proxmox_ceph_pool" "archive" {
node_name = "pve"
name = "archive"
erasure_coding = {
k = 4
m = 2
}
}
resource "proxmox_storage_rbd" "erasure_coded" {
id = "ceph-archive"
pool = proxmox_ceph_pool.archive.metadata_pool_name
data_pool = proxmox_ceph_pool.archive.data_pool.name
content = ["images"]
}
Schema¶
Required¶
id(String) The unique identifier of the storage.pool(String) The name of the Ceph pool that holds the storage's images. For an erasure-codedproxmox_ceph_pool, this is itsmetadata_pool_name, anddata_poolis itsdata_pool.name.
Optional¶
content(Set of String) The content types that can be stored on this storage. Valid values:images(VM disk images),rootdir(container root directories). Proxmox defaults toimages.data_pool(String) The name of the erasure-coded Ceph pool that holds the image data. The image metadata stays inpool.disable(Boolean) Whether the storage is disabled.krbd(Boolean) Whether to always access the images through the kernel RBD module instead of librbd. Containers always use the kernel module.namespace(String) The RBD namespace withinpoolfor the storage's images. Proxmox doesn't create the namespace.nodes(Set of String) A list of nodes where this storage is available.
Read-Only¶
shared(Boolean) Whether the storage is shared across all nodes. Proxmox always shares RBD storage.
Import¶
Import is supported using the following syntax: