Back to Talos

ExistingVolumeConfig

website/content/v1.14/reference/configuration/block/existingvolumeconfig.md

1.14.03.5 KB
Original Source
<!-- markdownlint-disable -->

{{< highlight yaml >}} apiVersion: v1alpha1 kind: ExistingVolumeConfig name: my-existing-volume # Name of the volume.

The discovery describes how to find a volume.

discovery: # The volume selector expression. volumeSelector: match: volume.partition_label == "MY-DATA" # The Common Expression Language (CEL) expression to match the volume. {{< /highlight >}}

FieldTypeDescriptionValue(s)
namestringName of the volume.

Name can only contain: lowercase and uppercase ASCII letters, digits, and hyphens. | | |discovery |<a href="#ExistingVolumeConfig.discovery">VolumeDiscoverySpec</a> |The discovery describes how to find a volume. | | |mount |<a href="#ExistingVolumeConfig.mount">ExistingMountSpec</a> |The mount describes additional mount options. | | |trim |<a href="#ExistingVolumeConfig.trim">TrimConfig</a> |The trim describes the per-volume filesystem trim (fstrim) configuration. | | |scrub |<a href="#ExistingVolumeConfig.scrub">ScrubConfig</a> |The scrub describes the per-volume filesystem scrub configuration. | |

discovery {#ExistingVolumeConfig.discovery}

VolumeDiscoverySpec describes how the volume is discovered.

FieldTypeDescriptionValue(s)
volumeSelector<a href="#ExistingVolumeConfig.discovery.volumeSelector">VolumeSelector</a>The volume selector expression.

volumeSelector {#ExistingVolumeConfig.discovery.volumeSelector}

VolumeSelector selects an existing volume.

FieldTypeDescriptionValue(s)
matchExpressionThe Common Expression Language (CEL) expression to match the volume. <details><summary>Show example(s)</summary>match volumes with partition label MY-DATA:{{< highlight yaml >}}
match: volume.partition_label == "MY-DATA"
{{< /highlight >}}match xfs volume on disk with serial 'SERIAL123':{{< highlight yaml >}}
match: volume.name == "xfs" && disk.serial == "SERIAL123"
{{< /highlight >}}</details>

mount {#ExistingVolumeConfig.mount}

ExistingMountSpec describes how the volume is mounted.

FieldTypeDescriptionValue(s)
readOnlyboolMount the volume read-only.
disableAccessTimeboolIf true, disable file access time updates.
secureboolEnable secure mount options (nosuid, nodev, noexec).

Defaults to true for better security. | |

trim {#ExistingVolumeConfig.trim}

TrimConfig describes per-volume filesystem trim (fstrim) configuration.

It overrides the global FilesystemTrimConfig for the volume.

FieldTypeDescriptionValue(s)
enabledboolEnable or disable trimming for this volume.

If not set, trimming is enabled when the global FilesystemTrimConfig is present. | | |interval |Duration |The interval at which the volume is trimmed, overriding the global trim interval. | |

scrub {#ExistingVolumeConfig.scrub}

ScrubConfig describes per-volume filesystem scrub configuration.

It overrides the global FilesystemScrubConfig for the volume.

FieldTypeDescriptionValue(s)
enabledboolEnable or disable scrubbing for this volume.

If not set, scrubbing is enabled by default when scrub section is present. | | |interval |Duration |The interval at which the volume is scrubbed, overriding the global scrub interval. | |