Files
Michal Nasiadka ac402eb8f8 Add oslo.config-based cluster label registry with auto-docs
Introduces a [capi_helm_cluster_labels] oslo.config group that serves
as the authoritative registry for all supported cluster labels. Each
label is defined as a typed oslo.config option (BoolOpt/IntOpt/StrOpt)
with a default value and help text, which operators can override
site-wide in magnum.conf and users can override per-cluster via
Magnum labels.

The five csi_cinder_* options previously scattered in [capi_helm] are
migrated to the new group with deprecated_opts so existing magnum.conf
files remain compatible without changes.

_label(), _get_label_bool(), _get_label_int() now raise ValueError for
any key not registered in the new group. A new _get_label_csv() method
handles the comma-separated api_master_lb_allowed_cidrs label.

A new AST-based unit test (TestClusterLabelRegistry) walks driver.py
at test time and asserts that every string-literal key passed to any
_label* method is present in capi_helm_cluster_labels_opts, preventing
unregistered labels from being silently introduced.

Documentation is updated to drop the hand-maintained label table in
favour of a cross-reference to the Configuration Reference page, which
oslo_config.sphinxext now auto-generates from the new group alongside
the existing [capi_helm] section.

Generated-By: Claude Sonnet 4.6
Change-Id: I2eb36d4c9bddc9d378b05bce1640d8a6d479552b
Signed-off-by: Michal Nasiadka <mnasiadka@gmail.com>
2026-06-02 09:19:16 +00:00
..