Skip to content

fix: nvca-operator chart clusterSource defaults to self-managed instead of ngc-managed in 3.1.0 #704

Description

@apartha-nv

Problem

Two bugs affect nvca-operator 3.1.0 upgrades:

Bug 1 - Wrong clusterSource default

The 3.1.0 chart bakes ngcConfig.clusterSource: self-managed as the default. The correct
default for the public chart is ngc-managed. NGC UI-generated install commands do not pass
--set ngcConfig.clusterSource=..., so any cluster installed with the 3.1.0 chart without
an explicit override never registers with the NVCA agent.

Bug 2 - Nil pointer on upgrade from 3.0.x

deploy/helm/nvca-operator/nvca-operator/templates/self-managed-nvcfbackend-cm.yaml evaluates
.Values.selfManaged.imageCredHelper.imageRepository and .Values.selfManaged.sharedStorage.imageRepository
unconditionally in the ConfigMap metadata section before the clusterSource guard on line 37.
These sub-keys were added in 3.1.0. When upgrading from 3.0.x with --reuse-values, the stored
values do not contain these sub-keys, making their parent maps nil. Accessing .imageRepository
on a nil interface panics with: nil pointer evaluating interface {}.imageRepository.

This panic affects all cluster types (including ngc-managed) because the metadata block runs
regardless of clusterSource.

Fix

  • Restore ngcConfig.clusterSource: ngc-managed as the chart default in both the vendoring
    script and the published values.yaml.
  • Add ngcConfig.clusterSource: self-managed to the self-managed stack helmfile so that
    self-hosted installs continue to work correctly.
  • Use | default dict before accessing .imageRepository on selfManaged.imageCredHelper
    and selfManaged.sharedStorage to guard against nil parents on upgrade.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions