proxmox-csi: opt SCs into pvc-autoresizer (resize.topolvm.io/enabled=true)

Without this annotation on the StorageClass, pvc-autoresizer's controller
filters the SC out at the index lookup stage and never patches any of its
PVCs, regardless of utilization or per-PVC threshold/increase/storage_limit
annotations. Internal metric pvcautoresizer_loop_seconds_total ticked but
no PVCs were ever evaluated — visible cluster-wide as PVAutoExpanding alerts
firing for forgejo-data-encrypted (82%) and audit-vault-0 (81%) without any
ResizeStarted events ever following.

The Prometheus scrape-config fix in 9d5da4d8 was a prerequisite (autoresizer
reads kubelet_volume_stats_available_bytes) but not sufficient on its own.

Also pinning chart version to 0.5.6 so the next apply doesn't incidentally
bump to 0.5.7.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
Viktor Barzin 2026-05-10 18:22:25 +00:00
parent ea9b5542d1
commit ff5416ff40

View file

@ -21,6 +21,7 @@ resource "helm_release" "proxmox_csi" {
repository = "oci://ghcr.io/sergelogvinov/charts"
chart = "proxmox-csi-plugin"
version = "0.5.6"
values = [yamlencode({
config = {
@ -33,7 +34,11 @@ resource "helm_release" "proxmox_csi" {
}]
}
# StorageClass for block volumes on existing HDD thin pool
# StorageClass for block volumes on existing HDD thin pool.
# `resize.topolvm.io/enabled=true` opts the SC into pvc-autoresizer:
# without it, the controller filters this SC out and never patches its
# PVCs no matter how full they get. Required alongside the per-PVC
# threshold/increase/storage_limit annotations.
storageClass = [
{
name = "proxmox-lvm"
@ -44,6 +49,9 @@ resource "helm_release" "proxmox_csi" {
cache = "none"
volumeBindingMode = "WaitForFirstConsumer"
allowVolumeExpansion = true
annotations = {
"resize.topolvm.io/enabled" = "true"
}
},
{
name = "proxmox-lvm-encrypted"
@ -54,6 +62,9 @@ resource "helm_release" "proxmox_csi" {
cache = "none"
volumeBindingMode = "WaitForFirstConsumer"
allowVolumeExpansion = true
annotations = {
"resize.topolvm.io/enabled" = "true"
}
extraParameters = {
"csi.storage.k8s.io/node-stage-secret-name" = "proxmox-csi-encryption"
"csi.storage.k8s.io/node-stage-secret-namespace" = "kube-system"