Skip to content

Commit a508af5

Browse files
aniruddha2000janiskemper
authored andcommitted
Rename helmChartName to Name
Signed-off-by: Aniruddha Basak <[email protected]>
1 parent eeccb83 commit a508af5

File tree

8 files changed

+59
-56
lines changed

8 files changed

+59
-56
lines changed

api/v1alpha1/clusteraddon_types.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ var (
6363
type StageStatus struct {
6464
// Name represent name of the helm chart
6565
// +optional
66-
Name string `json:"helmChartName"`
66+
Name string `json:"name"`
6767

6868
// Action is the action of the helm chart. e.g. - apply and delete.
6969
// +optional
@@ -133,9 +133,9 @@ type ClusterAddon struct {
133133
}
134134

135135
// GetStagePhase returns helm chart status for the helm chart.
136-
func (r *ClusterAddon) GetStagePhase(helmChartName string, action clusteraddon.Action) StagePhase {
136+
func (r *ClusterAddon) GetStagePhase(stageName string, action clusteraddon.Action) StagePhase {
137137
for _, stage := range r.Status.Stages {
138-
if stage.Name == helmChartName && stage.Action == action {
138+
if stage.Name == stageName && stage.Action == action {
139139
return stage.Phase
140140
}
141141
}
@@ -145,9 +145,9 @@ func (r *ClusterAddon) GetStagePhase(helmChartName string, action clusteraddon.A
145145
}
146146

147147
// SetStagePhase sets the helm chart status phase.
148-
func (r *ClusterAddon) SetStagePhase(helmChartName string, action clusteraddon.Action, phase StagePhase) {
148+
func (r *ClusterAddon) SetStagePhase(stageName string, action clusteraddon.Action, phase StagePhase) {
149149
for i := range r.Status.Stages {
150-
if r.Status.Stages[i].Name == helmChartName && r.Status.Stages[i].Action == action {
150+
if r.Status.Stages[i].Name == stageName && r.Status.Stages[i].Action == action {
151151
r.Status.Stages[i].Phase = phase
152152
}
153153
}

config/crd/bases/clusterstack.x-k8s.io_clusteraddons.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ spec:
217217
description: Action is the action of the helm chart. e.g. -
218218
apply and delete.
219219
type: string
220-
helmChartName:
220+
name:
221221
description: Name represent name of the helm chart
222222
type: string
223223
phase:

internal/controller/clusteraddon_controller.go

Lines changed: 37 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ func (r *ClusterAddonReconciler) Reconcile(ctx context.Context, req reconcile.Re
322322
if clusterAddon.Status.Ready || len(clusterAddon.Status.Stages) == 0 {
323323
clusterAddon.Status.Stages = make([]csov1alpha1.StageStatus, len(clusterAddonConfig.AddonStages[clusterAddon.Spec.Hook]))
324324
for i, stage := range clusterAddonConfig.AddonStages[clusterAddon.Spec.Hook] {
325-
clusterAddon.Status.Stages[i].Name = stage.HelmChartName
325+
clusterAddon.Status.Stages[i].Name = stage.Name
326326
clusterAddon.Status.Stages[i].Action = stage.Action
327327
clusterAddon.Status.Stages[i].Phase = csov1alpha1.StagePhasePending
328328
}
@@ -337,7 +337,7 @@ func (r *ClusterAddonReconciler) Reconcile(ctx context.Context, req reconcile.Re
337337
if clusterAddon.Status.Ready || len(clusterAddon.Status.Stages) == 0 {
338338
clusterAddon.Status.Stages = make([]csov1alpha1.StageStatus, len(clusterAddonConfig.AddonStages["BeforeClusterUpgrade"]))
339339
for i, stage := range clusterAddonConfig.AddonStages["BeforeClusterUpgrade"] {
340-
clusterAddon.Status.Stages[i].Name = stage.HelmChartName
340+
clusterAddon.Status.Stages[i].Name = stage.Name
341341
clusterAddon.Status.Stages[i].Action = stage.Action
342342
clusterAddon.Status.Stages[i].Phase = csov1alpha1.StagePhasePending
343343
}
@@ -361,6 +361,7 @@ func (r *ClusterAddonReconciler) Reconcile(ctx context.Context, req reconcile.Re
361361
// we just take the Helm charts that are supposed to be installed in the BeforeClusterUpgrade hook and apply them.
362362
if oldRelease != nil && oldRelease.Meta.Versions.Kubernetes == releaseAsset.Meta.Versions.Kubernetes {
363363
clusterAddon.Spec.Hook = "BeforeClusterUpgrade"
364+
364365
for _, stage := range clusterAddonConfig.AddonStages["BeforeClusterUpgrade"] {
365366
shouldRequeue, err := r.executeStage(ctx, stage, in)
366367
if err != nil {
@@ -428,7 +429,7 @@ func (r *ClusterAddonReconciler) Reconcile(ctx context.Context, req reconcile.Re
428429
for _, stage := range clusterAddonConfig.AddonStages[clusterAddon.Spec.Hook] {
429430
shouldRequeue, err := r.executeStage(ctx, stage, in)
430431
if err != nil {
431-
return reconcile.Result{}, fmt.Errorf("failed to execute stage: %q: %w", stage.HelmChartName, err)
432+
return reconcile.Result{}, fmt.Errorf("failed to execute stage: %q: %w", stage.Name, err)
432433
}
433434
if shouldRequeue {
434435
return reconcile.Result{RequeueAfter: 20 * time.Second}, nil
@@ -490,14 +491,14 @@ func (r *ClusterAddonReconciler) getNewReleaseObjects(ctx context.Context, in *t
490491
)
491492

492493
for _, stage := range clusterAddonConfig.AddonStages[in.clusterAddon.Spec.Hook] {
493-
if _, err := os.Stat(filepath.Join(in.newDestinationClusterAddonChartDir, stage.HelmChartName, release.OverwriteYaml)); err == nil {
494-
newBuildTemplate, err = buildTemplateFromClusterAddonValues(ctx, filepath.Join(in.newDestinationClusterAddonChartDir, stage.HelmChartName, release.OverwriteYaml), in.cluster, r.Client)
494+
if _, err := os.Stat(filepath.Join(in.newDestinationClusterAddonChartDir, stage.Name, release.OverwriteYaml)); err == nil {
495+
newBuildTemplate, err = buildTemplateFromClusterAddonValues(ctx, filepath.Join(in.newDestinationClusterAddonChartDir, stage.Name, release.OverwriteYaml), in.cluster, r.Client)
495496
if err != nil {
496497
return nil, fmt.Errorf("failed to build template from new cluster addon values of the latest cluster stack: %w", err)
497498
}
498499
}
499500

500-
helmTemplate, err := helmTemplateClusterAddon(filepath.Join(in.newDestinationClusterAddonChartDir, stage.HelmChartName), newBuildTemplate)
501+
helmTemplate, err := helmTemplateClusterAddon(filepath.Join(in.newDestinationClusterAddonChartDir, stage.Name), newBuildTemplate)
501502
if err != nil {
502503
return nil, fmt.Errorf("failed to template new helm chart of the latest cluster stack: %w", err)
503504
}
@@ -566,14 +567,14 @@ func (r *ClusterAddonReconciler) getOldReleaseObjects(ctx context.Context, in *t
566567
}
567568

568569
for _, stage := range clusterAddonConfig.AddonStages[hook] {
569-
if _, err := os.Stat(filepath.Join(in.oldDestinationClusterAddonChartDir, stage.HelmChartName, release.OverwriteYaml)); err == nil {
570-
newBuildTemplate, err = buildTemplateFromClusterAddonValues(ctx, filepath.Join(in.oldDestinationClusterAddonChartDir, stage.HelmChartName, release.OverwriteYaml), in.cluster, r.Client)
570+
if _, err := os.Stat(filepath.Join(in.oldDestinationClusterAddonChartDir, stage.Name, release.OverwriteYaml)); err == nil {
571+
newBuildTemplate, err = buildTemplateFromClusterAddonValues(ctx, filepath.Join(in.oldDestinationClusterAddonChartDir, stage.Name, release.OverwriteYaml), in.cluster, r.Client)
571572
if err != nil {
572573
return nil, fmt.Errorf("failed to build template from new cluster addon values: %w", err)
573574
}
574575
}
575576

576-
helmTemplate, err := helmTemplateClusterAddon(filepath.Join(in.oldDestinationClusterAddonChartDir, stage.HelmChartName), newBuildTemplate)
577+
helmTemplate, err := helmTemplateClusterAddon(filepath.Join(in.oldDestinationClusterAddonChartDir, stage.Name), newBuildTemplate)
577578
if err != nil {
578579
return nil, fmt.Errorf("failed to template new helm chart: %w", err)
579580
}
@@ -737,7 +738,7 @@ func (r *ClusterAddonReconciler) executeStage(ctx context.Context, stage *cluste
737738
err error
738739
)
739740

740-
_, exists := in.chartMap[stage.HelmChartName]
741+
_, exists := in.chartMap[stage.Name]
741742
if !exists {
742743
// do not reconcile by returning error, just create an event.
743744
conditions.MarkFalse(
@@ -746,44 +747,44 @@ func (r *ClusterAddonReconciler) executeStage(ctx context.Context, stage *cluste
746747
csov1alpha1.HelmChartMissingReason,
747748
clusterv1.ConditionSeverityInfo,
748749
"helm chart name doesn't exists in the cluster addon helm chart: %q",
749-
stage.HelmChartName,
750+
stage.Name,
750751
)
751752
return false, nil
752753
}
753754

754755
check:
755-
switch in.clusterAddon.GetStagePhase(stage.HelmChartName, stage.Action) {
756+
switch in.clusterAddon.GetStagePhase(stage.Name, stage.Action) {
756757
case csov1alpha1.StagePhasePending, csov1alpha1.StagePhaseWaitingForPreCondition:
757758
// If WaitForPreCondition is mentioned.
758759
if !reflect.DeepEqual(stage.WaitForPreCondition, clusteraddon.WaitForCondition{}) {
759760
// Evaluate the condition.
760-
logger.V(1).Info("starting to evaluate pre condition", "clusterStack", in.clusterAddon.Spec.ClusterStack, "helm chart", stage.HelmChartName, "hook", in.clusterAddon.Spec.Hook)
761+
logger.V(1).Info("starting to evaluate pre condition", "clusterStack", in.clusterAddon.Spec.ClusterStack, "name", stage.Name, "hook", in.clusterAddon.Spec.Hook)
761762
if err := getDynamicResourceAndEvaluateCEL(ctx, in.dynamicClient, in.discoverClient, stage.WaitForPreCondition); err != nil {
762763
if errors.Is(err, clusteraddon.ErrConditionNotMatch) {
763764
conditions.MarkFalse(
764765
in.clusterAddon,
765766
csov1alpha1.EvaluatedCELCondition,
766767
csov1alpha1.FailedToEvaluatePreConditionReason,
767768
clusterv1.ConditionSeverityInfo,
768-
"failed to successfully evaluate pre condition: %q: %s", stage.HelmChartName, err.Error(),
769+
"failed to successfully evaluate pre condition: %q: %s", stage.Name, err.Error(),
769770
)
770771

771-
in.clusterAddon.SetStagePhase(stage.HelmChartName, stage.Action, csov1alpha1.StagePhaseWaitingForPreCondition)
772+
in.clusterAddon.SetStagePhase(stage.Name, stage.Action, csov1alpha1.StagePhaseWaitingForPreCondition)
772773

773774
return true, nil
774775
}
775776
return false, fmt.Errorf("failed to get dynamic resource and evaluate cel expression for pre condition: %w", err)
776777
}
777-
logger.V(1).Info("finished evaluating pre condition", "clusterStack", in.clusterAddon.Spec.ClusterStack, "helm chart", stage.HelmChartName, "hook", in.clusterAddon.Spec.Hook)
778+
logger.V(1).Info("finished evaluating pre condition", "clusterStack", in.clusterAddon.Spec.ClusterStack, "name", stage.Name, "hook", in.clusterAddon.Spec.Hook)
778779
}
779780

780-
in.clusterAddon.SetStagePhase(stage.HelmChartName, stage.Action, csov1alpha1.StagePhaseApplyingOrDeleting)
781+
in.clusterAddon.SetStagePhase(stage.Name, stage.Action, csov1alpha1.StagePhaseApplyingOrDeleting)
781782
goto check
782783

783784
case csov1alpha1.StagePhaseApplyingOrDeleting:
784785
if stage.Action == clusteraddon.Apply {
785-
logger.V(1).Info("starting to apply helm chart", "clusterStack", in.clusterAddon.Spec.ClusterStack, "helm chart", stage.HelmChartName, "hook", in.clusterAddon.Spec.Hook)
786-
shouldRequeue, err = r.templateAndApplyNewClusterStackAddonHelmChart(ctx, in, stage.HelmChartName)
786+
logger.V(1).Info("starting to apply helm chart", "clusterStack", in.clusterAddon.Spec.ClusterStack, "name", stage.Name, "hook", in.clusterAddon.Spec.Hook)
787+
shouldRequeue, err = r.templateAndApplyNewClusterStackAddonHelmChart(ctx, in, stage.Name)
787788
if err != nil {
788789
return false, fmt.Errorf("failed to helm template and apply: %w", err)
789790
}
@@ -793,22 +794,22 @@ check:
793794
csov1alpha1.HelmChartAppliedCondition,
794795
csov1alpha1.FailedToApplyObjectsReason,
795796
clusterv1.ConditionSeverityInfo,
796-
"failed to successfully apply helm chart: %q", stage.HelmChartName,
797+
"failed to successfully apply helm chart: %q", stage.Name,
797798
)
798799

799800
return true, nil
800801
}
801-
logger.V(1).Info("finished applying helm chart", "clusterStack", in.clusterAddon.Spec.ClusterStack, "helm chart", stage.HelmChartName, "hook", in.clusterAddon.Spec.Hook)
802+
logger.V(1).Info("finished applying helm chart", "clusterStack", in.clusterAddon.Spec.ClusterStack, "name", stage.Name, "hook", in.clusterAddon.Spec.Hook)
802803

803804
// remove status resource if applied successfully
804805
in.clusterAddon.Status.Resources = make([]*csov1alpha1.Resource, 0)
805806

806-
in.clusterAddon.SetStagePhase(stage.HelmChartName, stage.Action, csov1alpha1.StagePhaseWaitingForPostCondition)
807+
in.clusterAddon.SetStagePhase(stage.Name, stage.Action, csov1alpha1.StagePhaseWaitingForPostCondition)
807808
goto check
808809
} else {
809810
// Delete part
810-
logger.V(1).Info("starting to delete helm chart", "clusterStack", in.clusterAddon.Spec.ClusterStack, "helm chart", stage.HelmChartName, "hook", in.clusterAddon.Spec.Hook)
811-
shouldRequeue, err = helmTemplateAndDeleteNewClusterStack(ctx, in, stage.HelmChartName)
811+
logger.V(1).Info("starting to delete helm chart", "clusterStack", in.clusterAddon.Spec.ClusterStack, "name", stage.Name, "hook", in.clusterAddon.Spec.Hook)
812+
shouldRequeue, err = helmTemplateAndDeleteNewClusterStack(ctx, in, stage.Name)
812813
if err != nil {
813814
return false, fmt.Errorf("failed to delete helm chart: %w", err)
814815
}
@@ -818,43 +819,43 @@ check:
818819
csov1alpha1.HelmChartDeletedCondition,
819820
csov1alpha1.FailedToDeleteObjectsReason,
820821
clusterv1.ConditionSeverityInfo,
821-
"failed to successfully delete helm chart: %q", stage.HelmChartName,
822+
"failed to successfully delete helm chart: %q", stage.Name,
822823
)
823824

824825
return true, nil
825826
}
826-
logger.V(1).Info("finished deleting helm chart", "clusterStack", in.clusterAddon.Spec.ClusterStack, "helm chart", stage.HelmChartName, "hook", in.clusterAddon.Spec.Hook)
827+
logger.V(1).Info("finished deleting helm chart", "clusterStack", in.clusterAddon.Spec.ClusterStack, "name", stage.Name, "hook", in.clusterAddon.Spec.Hook)
827828

828829
// remove status resource if deleted successfully
829830
in.clusterAddon.Status.Resources = make([]*csov1alpha1.Resource, 0)
830831

831-
in.clusterAddon.SetStagePhase(stage.HelmChartName, stage.Action, csov1alpha1.StagePhaseWaitingForPostCondition)
832+
in.clusterAddon.SetStagePhase(stage.Name, stage.Action, csov1alpha1.StagePhaseWaitingForPostCondition)
832833
goto check
833834
}
834835

835836
case csov1alpha1.StagePhaseWaitingForPostCondition:
836837
// If WaitForPostCondition is mentioned.
837838
if !reflect.DeepEqual(stage.WaitForPostCondition, clusteraddon.WaitForCondition{}) {
838839
// Evaluate the condition.
839-
logger.V(1).Info("starting to evaluate post condition", "clusterStack", in.clusterAddon.Spec.ClusterStack, "helm chart", stage.HelmChartName, "hook", in.clusterAddon.Spec.Hook)
840+
logger.V(1).Info("starting to evaluate post condition", "clusterStack", in.clusterAddon.Spec.ClusterStack, "name", stage.Name, "hook", in.clusterAddon.Spec.Hook)
840841
if err := getDynamicResourceAndEvaluateCEL(ctx, in.dynamicClient, in.discoverClient, stage.WaitForPostCondition); err != nil {
841842
if errors.Is(err, clusteraddon.ErrConditionNotMatch) {
842843
conditions.MarkFalse(
843844
in.clusterAddon,
844845
csov1alpha1.EvaluatedCELCondition,
845846
csov1alpha1.FailedToEvaluatePostConditionReason,
846847
clusterv1.ConditionSeverityInfo,
847-
"failed to successfully evaluate post condition: %q: %s", stage.HelmChartName, err.Error(),
848+
"failed to successfully evaluate post condition: %q: %s", stage.Name, err.Error(),
848849
)
849850

850851
return true, nil
851852
}
852853
return false, fmt.Errorf("failed to get dynamic resource and evaluate cel expression for post condition: %w", err)
853854
}
854-
logger.V(1).Info("finished evaluating post condition", "clusterStack", in.clusterAddon.Spec.ClusterStack, "helm chart", stage.HelmChartName, "hook", in.clusterAddon.Spec.Hook)
855+
logger.V(1).Info("finished evaluating post condition", "clusterStack", in.clusterAddon.Spec.ClusterStack, "name", stage.Name, "hook", in.clusterAddon.Spec.Hook)
855856
}
856857

857-
in.clusterAddon.SetStagePhase(stage.HelmChartName, stage.Action, csov1alpha1.StagePhaseDone)
858+
in.clusterAddon.SetStagePhase(stage.Name, stage.Action, csov1alpha1.StagePhaseDone)
858859
}
859860

860861
return false, nil
@@ -926,7 +927,7 @@ func (r *ClusterAddonReconciler) downloadOldClusterStackRelease(ctx context.Cont
926927
return &releaseAsset, false, nil
927928
}
928929

929-
func (r *ClusterAddonReconciler) templateAndApplyNewClusterStackAddonHelmChart(ctx context.Context, in *templateAndApplyClusterAddonInput, helmChartName string) (bool, error) {
930+
func (r *ClusterAddonReconciler) templateAndApplyNewClusterStackAddonHelmChart(ctx context.Context, in *templateAndApplyClusterAddonInput, name string) (bool, error) {
930931
var (
931932
oldHelmTemplate []byte
932933
oldBuildTemplate []byte
@@ -935,7 +936,7 @@ func (r *ClusterAddonReconciler) templateAndApplyNewClusterStackAddonHelmChart(c
935936
)
936937

937938
if in.oldDestinationClusterAddonChartDir != "" {
938-
oldClusterStackSubDirPath := filepath.Join(in.oldDestinationClusterAddonChartDir, helmChartName)
939+
oldClusterStackSubDirPath := filepath.Join(in.oldDestinationClusterAddonChartDir, name)
939940

940941
// we skip helm templating if last cluster stack don't follow the new convention.
941942
if _, err := os.Stat(filepath.Join(oldClusterStackSubDirPath, release.OverwriteYaml)); err == nil {
@@ -951,7 +952,7 @@ func (r *ClusterAddonReconciler) templateAndApplyNewClusterStackAddonHelmChart(c
951952
}
952953
}
953954

954-
newClusterStackSubDirPath := filepath.Join(in.newDestinationClusterAddonChartDir, helmChartName)
955+
newClusterStackSubDirPath := filepath.Join(in.newDestinationClusterAddonChartDir, name)
955956

956957
if _, err := os.Stat(filepath.Join(newClusterStackSubDirPath, release.OverwriteYaml)); err == nil {
957958
newBuildTemplate, err = buildTemplateFromClusterAddonValues(ctx, filepath.Join(newClusterStackSubDirPath, release.OverwriteYaml), in.cluster, r.Client)
@@ -976,13 +977,13 @@ func (r *ClusterAddonReconciler) templateAndApplyNewClusterStackAddonHelmChart(c
976977
return shouldRequeue, nil
977978
}
978979

979-
func helmTemplateAndDeleteNewClusterStack(ctx context.Context, in *templateAndApplyClusterAddonInput, helmChartName string) (bool, error) {
980+
func helmTemplateAndDeleteNewClusterStack(ctx context.Context, in *templateAndApplyClusterAddonInput, name string) (bool, error) {
980981
var (
981982
buildTemplate []byte
982983
err error
983984
)
984985

985-
newClusterStackSubDirPath := filepath.Join(in.newDestinationClusterAddonChartDir, helmChartName)
986+
newClusterStackSubDirPath := filepath.Join(in.newDestinationClusterAddonChartDir, name)
986987
newHelmTemplate, err := helmTemplateClusterAddon(newClusterStackSubDirPath, buildTemplate)
987988
if err != nil {
988989
return false, fmt.Errorf("failed to template new helm chart: %w", err)

internal/test/integration/workloadcluster/controller_suite_test.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,16 @@ import (
3131
)
3232

3333
const (
34-
timeout = time.Second * 3
34+
timeout = time.Second * 2
3535
interval = 100 * time.Millisecond
3636

3737
testClusterStackName = "docker-ferrol-1-27-v1"
3838
testClusterStackNameV2 = "docker-ferrol-1-27-v2"
3939
testClusterStackNameV3 = "docker-ferrol-1-27-v3"
4040

41+
// cluster stack.
4142
testNewWayClusterStackName = "docker-ferrol-1-27-v0-sha-hipstsw"
43+
// cluster class.
4244
testNewWayClusterClassName = "docker-ferrol-1-27-v0-sha.hipstsw"
4345
)
4446

pkg/clusteraddon/clusteraddon.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ type WaitForCondition struct {
5757

5858
// Stage is a stage of a hook in which a certain Helm chart is applied and pre- and post-conditions are evaluated if they exist.
5959
type Stage struct {
60-
HelmChartName string `yaml:"helmChartName"`
60+
Name string `yaml:"name"`
6161
Action Action `yaml:"action"`
6262
WaitForPreCondition WaitForCondition `yaml:"waitForPreCondition,omitempty"`
6363
WaitForPostCondition WaitForCondition `yaml:"waitForPostCondition,omitempty"`

test/cluster-stacks/1/docker/ferrol/1-27/clusteraddon.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@ apiVersion: clusteraddonconfig.x-k8s.io/v1alpha1
22
clusterAddonVersion: clusteraddons.clusterstack.x-k8s.io/v1alpha1
33
addonStages:
44
AfterControlPlaneInitialized:
5-
- helmChartName: cni
5+
- name: cni
66
action: apply
7-
- helmChartName: metrics-server
7+
- name: metrics-server
88
action: apply
9-
BeforeClusterUpgrade:
10-
- helmChartName: ngnix
9+
name:
10+
- name: ngnix
1111
action: apply
1212
waitForPostCondition:
1313
objects:

test/cluster-stacks/2/docker/ferrol/1-27/clusteraddon.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,16 @@ apiVersion: clusteraddonconfig.x-k8s.io/v1alpha1
22
clusterAddonVersion: clusteraddons.clusterstack.x-k8s.io/v1alpha1
33
addonStages:
44
AfterControlPlaneInitialized:
5-
- helmChartName: cni
5+
- name: cni
66
action: apply
7-
- helmChartName: metrics-server
7+
- name: metrics-server
88
action: apply
9-
BeforeClusterUpgrade:
10-
- helmChartName: cni
9+
name:
10+
- name: cni
1111
action: apply
12-
- helmChartName: metrics-server
12+
- name: metrics-server
1313
action: apply
14-
- helmChartName: ngnix
14+
- name: ngnix
1515
action: apply
1616
waitForPostCondition:
1717
objects:

test/releases/cluster-stacks/docker-ferrol-1-27-v0-sha-hipstsw/clusteraddon.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@ apiVersion: clusteraddonconfig.x-k8s.io/v1alpha1
22
clusterAddonVersion: clusteraddons.clusterstack.x-k8s.io/v1alpha1
33
addonStages:
44
AfterControlPlaneInitialized:
5-
- helmChartName: metrics-server
5+
- name: metrics-server
66
action: apply
77
BeforeClusterUpgrade:
8-
- helmChartName: ngnix
8+
- name: ngnix
99
action: apply
1010
waitForPostCondition:
1111
objects:

0 commit comments

Comments
 (0)