Skip to content

Commit

Permalink
🌱 Use upstream cluster RESTConfig utility
Browse files Browse the repository at this point in the history
This commit simplifies the codebase by removing custom kubeconfig code
and instead using the existing fucntionality from cluster-api project.
  • Loading branch information
jimmidyson committed May 29, 2024
1 parent 2e29f0c commit db42942
Show file tree
Hide file tree
Showing 10 changed files with 104 additions and 330 deletions.
28 changes: 27 additions & 1 deletion controllers/controllers_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ import (
addonsv1alpha1 "sigs.k8s.io/cluster-api-addon-provider-helm/api/v1alpha1"
clusterv1 "sigs.k8s.io/cluster-api/api/v1beta1"
"sigs.k8s.io/cluster-api/util/conditions"
"sigs.k8s.io/cluster-api/util/secret"
"sigs.k8s.io/controller-runtime/pkg/client"
)

var (
testNamespace = "test-namespace"
kubeconfig = "test-kubeconfig"
newVersion = "new-version"

defaultProxy = &addonsv1alpha1.HelmChartProxy{
Expand Down Expand Up @@ -88,6 +88,30 @@ var (
}
)

func newKubeconfigSecretForCluster(cluster *clusterv1.Cluster) *corev1.Secret {
return &corev1.Secret{
ObjectMeta: metav1.ObjectMeta{
Name: cluster.Name + "-kubeconfig",
Namespace: cluster.Namespace,
},
StringData: map[string]string{
secret.KubeconfigDataName: `
apiVersion: v1
kind: Config
clusters:
- cluster:
server: http://127.0.0.1:8080
name: ` + cluster.Name + `
contexts:
- context:
cluster: ` + cluster.Name + `
name: ` + cluster.Name + `
current-context: ` + cluster.Name + `
`,
},
}
}

var _ = Describe("Testing HelmChartProxy and HelmReleaseProxy reconcile", func() {
var (
waitForHelmChartProxyCondition = func(objectKey client.ObjectKey, condition func(helmChartProxy *addonsv1alpha1.HelmChartProxy) bool) {
Expand Down Expand Up @@ -117,6 +141,8 @@ var _ = Describe("Testing HelmChartProxy and HelmReleaseProxy reconcile", func()
cluster := cluster1.DeepCopy()
err := k8sClient.Create(ctx, cluster)
Expect(err).ToNot(HaveOccurred())
err = k8sClient.Create(ctx, newKubeconfigSecretForCluster(cluster))
Expect(err).ToNot(HaveOccurred())

patch := client.MergeFrom(cluster.DeepCopy())
cluster.Status.Conditions = clusterv1.Conditions{
Expand Down
27 changes: 14 additions & 13 deletions controllers/helmreleaseproxy/helmreleaseproxy_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,11 @@ import (
apierrors "k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/types"
"k8s.io/client-go/rest"
addonsv1alpha1 "sigs.k8s.io/cluster-api-addon-provider-helm/api/v1alpha1"
"sigs.k8s.io/cluster-api-addon-provider-helm/internal"
clusterv1 "sigs.k8s.io/cluster-api/api/v1beta1"
"sigs.k8s.io/cluster-api/controllers/remote"
"sigs.k8s.io/cluster-api/util"
"sigs.k8s.io/cluster-api/util/conditions"
"sigs.k8s.io/cluster-api/util/patch"
Expand All @@ -46,9 +48,8 @@ import (
// HelmReleaseProxyReconciler reconciles a HelmReleaseProxy object.
type HelmReleaseProxyReconciler struct {
client.Client
Scheme *runtime.Scheme
KubeconfigGetter internal.Getter
HelmClient internal.Client
Scheme *runtime.Scheme
HelmClient internal.Client

// WatchFilterValue is the label value used to filter events prior to reconciliation.
WatchFilterValue string
Expand Down Expand Up @@ -152,7 +153,7 @@ func (r *HelmReleaseProxyReconciler) Reconcile(ctx context.Context, req ctrl.Req
// our finalizer is present, so lets handle any external dependency
if err := r.Client.Get(ctx, clusterKey, cluster); err == nil {
log.V(2).Info("Getting kubeconfig for cluster", "cluster", cluster.Name)
kubeconfig, err := r.KubeconfigGetter.GetClusterKubeconfig(ctx, clusterKey)
restConfig, err := remote.RESTConfig(ctx, "caaph", r.Client, clusterKey)
if err != nil {
wrappedErr := errors.Wrapf(err, "failed to get kubeconfig for cluster")
conditions.MarkFalse(helmReleaseProxy, addonsv1alpha1.ClusterAvailableCondition, addonsv1alpha1.GetKubeconfigFailedReason, clusterv1.ConditionSeverityError, wrappedErr.Error())
Expand All @@ -161,7 +162,7 @@ func (r *HelmReleaseProxyReconciler) Reconcile(ctx context.Context, req ctrl.Req
}
conditions.MarkTrue(helmReleaseProxy, addonsv1alpha1.ClusterAvailableCondition)

if err := r.reconcileDelete(ctx, helmReleaseProxy, r.HelmClient, kubeconfig); err != nil {
if err := r.reconcileDelete(ctx, helmReleaseProxy, r.HelmClient, restConfig); err != nil {
// if fail to delete the external dependency here, return with error
// so that it can be retried
return ctrl.Result{}, err
Expand Down Expand Up @@ -206,8 +207,8 @@ func (r *HelmReleaseProxyReconciler) Reconcile(ctx context.Context, req ctrl.Req
return ctrl.Result{}, nil
}

log.V(2).Info("Getting kubeconfig for cluster", "cluster", cluster.Name)
kubeconfig, err := r.KubeconfigGetter.GetClusterKubeconfig(ctx, clusterKey)
log.V(2).Info("Getting REST config for cluster", "cluster", cluster.Name)
restConfig, err := remote.RESTConfig(ctx, "caaph", r.Client, clusterKey)
if err != nil {
wrappedErr := errors.Wrapf(err, "failed to get kubeconfig for cluster")
conditions.MarkFalse(helmReleaseProxy, addonsv1alpha1.ClusterAvailableCondition, addonsv1alpha1.GetKubeconfigFailedReason, clusterv1.ConditionSeverityError, wrappedErr.Error())
Expand Down Expand Up @@ -249,14 +250,14 @@ func (r *HelmReleaseProxyReconciler) Reconcile(ctx context.Context, req ctrl.Req
}

log.V(2).Info("Reconciling HelmReleaseProxy", "releaseProxyName", helmReleaseProxy.Name)
err = r.reconcileNormal(ctx, helmReleaseProxy, r.HelmClient, credentialsPath, caFilePath, kubeconfig)
err = r.reconcileNormal(ctx, helmReleaseProxy, r.HelmClient, credentialsPath, caFilePath, restConfig)

return ctrl.Result{}, err
}

// reconcileNormal handles HelmReleaseProxy reconciliation when it is not being deleted. This will install or upgrade the HelmReleaseProxy on the Cluster.
// It will set the ReleaseName on the HelmReleaseProxy if the name is generated and also set the release status and release revision.
func (r *HelmReleaseProxyReconciler) reconcileNormal(ctx context.Context, helmReleaseProxy *addonsv1alpha1.HelmReleaseProxy, client internal.Client, credentialsPath, caFilePath string, kubeconfig string) error {
func (r *HelmReleaseProxyReconciler) reconcileNormal(ctx context.Context, helmReleaseProxy *addonsv1alpha1.HelmReleaseProxy, client internal.Client, credentialsPath, caFilePath string, restConfig *rest.Config) error {
log := ctrl.LoggerFrom(ctx)

log.V(2).Info("Reconciling HelmReleaseProxy on cluster", "HelmReleaseProxy", helmReleaseProxy.Name, "cluster", helmReleaseProxy.Spec.ClusterRef.Name)
Expand All @@ -268,7 +269,7 @@ func (r *HelmReleaseProxyReconciler) reconcileNormal(ctx context.Context, helmRe
})
}

release, err := client.InstallOrUpgradeHelmRelease(ctx, kubeconfig, credentialsPath, caFilePath, helmReleaseProxy.Spec)
release, err := client.InstallOrUpgradeHelmRelease(ctx, restConfig, credentialsPath, caFilePath, helmReleaseProxy.Spec)
if err != nil {
log.Error(err, fmt.Sprintf("Failed to install or upgrade release '%s' on cluster %s", helmReleaseProxy.Spec.ReleaseName, helmReleaseProxy.Spec.ClusterRef.Name))
conditions.MarkFalse(helmReleaseProxy, addonsv1alpha1.HelmReleaseReadyCondition, addonsv1alpha1.HelmInstallOrUpgradeFailedReason, clusterv1.ConditionSeverityError, err.Error())
Expand Down Expand Up @@ -297,12 +298,12 @@ func (r *HelmReleaseProxyReconciler) reconcileNormal(ctx context.Context, helmRe
}

// reconcileDelete handles HelmReleaseProxy deletion. This will uninstall the HelmReleaseProxy on the Cluster or return nil if the HelmReleaseProxy is not found.
func (r *HelmReleaseProxyReconciler) reconcileDelete(ctx context.Context, helmReleaseProxy *addonsv1alpha1.HelmReleaseProxy, client internal.Client, kubeconfig string) error {
func (r *HelmReleaseProxyReconciler) reconcileDelete(ctx context.Context, helmReleaseProxy *addonsv1alpha1.HelmReleaseProxy, client internal.Client, restConfig *rest.Config) error {
log := ctrl.LoggerFrom(ctx)

log.V(2).Info("Deleting HelmReleaseProxy on cluster", "HelmReleaseProxy", helmReleaseProxy.Name, "cluster", helmReleaseProxy.Spec.ClusterRef.Name)

_, err := client.GetHelmRelease(ctx, kubeconfig, helmReleaseProxy.Spec)
_, err := client.GetHelmRelease(ctx, restConfig, helmReleaseProxy.Spec)
if err != nil {
log.V(2).Error(err, "error getting release from cluster", "cluster", helmReleaseProxy.Spec.ClusterRef.Name)

Expand All @@ -320,7 +321,7 @@ func (r *HelmReleaseProxyReconciler) reconcileDelete(ctx context.Context, helmRe

log.V(2).Info("Preparing to uninstall release on cluster", "releaseName", helmReleaseProxy.Spec.ReleaseName, "clusterName", helmReleaseProxy.Spec.ClusterRef.Name)

response, err := client.UninstallHelmRelease(ctx, kubeconfig, helmReleaseProxy.Spec)
response, err := client.UninstallHelmRelease(ctx, restConfig, helmReleaseProxy.Spec)
if err != nil {
log.V(2).Info("Error uninstalling chart with Helm:", err)
conditions.MarkFalse(helmReleaseProxy, addonsv1alpha1.HelmReleaseReadyCondition, addonsv1alpha1.HelmReleaseDeletionFailedReason, clusterv1.ConditionSeverityError, err.Error())
Expand Down
33 changes: 17 additions & 16 deletions controllers/helmreleaseproxy/helmreleaseproxy_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/client-go/kubernetes/scheme"
"k8s.io/client-go/rest"
addonsv1alpha1 "sigs.k8s.io/cluster-api-addon-provider-helm/api/v1alpha1"
"sigs.k8s.io/cluster-api-addon-provider-helm/internal/mocks"
clusterv1 "sigs.k8s.io/cluster-api/api/v1beta1"
Expand All @@ -40,7 +41,7 @@ var (
ctx = ctrl.SetupSignalHandler()
fakeScheme = runtime.NewScheme()

kubeconfig = "test-kubeconfig"
restConfig = &rest.Config{}

defaultProxy = &addonsv1alpha1.HelmReleaseProxy{
TypeMeta: metav1.TypeMeta{
Expand Down Expand Up @@ -171,7 +172,7 @@ func TestReconcileNormal(t *testing.T) {
name: "successfully install a Helm release",
helmReleaseProxy: defaultProxy.DeepCopy(),
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.InstallOrUpgradeHelmRelease(ctx, kubeconfig, "", "", defaultProxy.DeepCopy().Spec).Return(&helmRelease.Release{
c.InstallOrUpgradeHelmRelease(ctx, restConfig, "", "", defaultProxy.DeepCopy().Spec).Return(&helmRelease.Release{
Name: "test-release",
Version: 1,
Info: &helmRelease.Info{
Expand All @@ -195,7 +196,7 @@ func TestReconcileNormal(t *testing.T) {
name: "successfully install a Helm release with a generated name",
helmReleaseProxy: generateNameProxy,
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.InstallOrUpgradeHelmRelease(ctx, kubeconfig, "", "", generateNameProxy.Spec).Return(&helmRelease.Release{
c.InstallOrUpgradeHelmRelease(ctx, restConfig, "", "", generateNameProxy.Spec).Return(&helmRelease.Release{
Name: "test-release",
Version: 1,
Info: &helmRelease.Info{
Expand All @@ -219,7 +220,7 @@ func TestReconcileNormal(t *testing.T) {
name: "Helm release pending",
helmReleaseProxy: defaultProxy.DeepCopy(),
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.InstallOrUpgradeHelmRelease(ctx, kubeconfig, "", "", defaultProxy.Spec).Return(&helmRelease.Release{
c.InstallOrUpgradeHelmRelease(ctx, restConfig, "", "", defaultProxy.Spec).Return(&helmRelease.Release{
Name: "test-release",
Version: 1,
Info: &helmRelease.Info{
Expand All @@ -246,7 +247,7 @@ func TestReconcileNormal(t *testing.T) {
name: "Helm client returns error",
helmReleaseProxy: defaultProxy.DeepCopy(),
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.InstallOrUpgradeHelmRelease(ctx, kubeconfig, "", "", defaultProxy.Spec).Return(nil, errInternal).Times(1)
c.InstallOrUpgradeHelmRelease(ctx, restConfig, "", "", defaultProxy.Spec).Return(nil, errInternal).Times(1)
},
expect: func(g *WithT, hrp *addonsv1alpha1.HelmReleaseProxy) {
_, ok := hrp.Annotations[addonsv1alpha1.IsReleaseNameGeneratedAnnotation]
Expand All @@ -264,7 +265,7 @@ func TestReconcileNormal(t *testing.T) {
name: "Helm release in a failed state, no client error",
helmReleaseProxy: defaultProxy.DeepCopy(),
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.InstallOrUpgradeHelmRelease(ctx, kubeconfig, "", "", defaultProxy.Spec).Return(&helmRelease.Release{
c.InstallOrUpgradeHelmRelease(ctx, restConfig, "", "", defaultProxy.Spec).Return(&helmRelease.Release{
Name: "test-release",
Version: 1,
Info: &helmRelease.Info{
Expand Down Expand Up @@ -304,7 +305,7 @@ func TestReconcileNormal(t *testing.T) {
Build(),
}

err := r.reconcileNormal(ctx, tc.helmReleaseProxy, clientMock, "", "", kubeconfig)
err := r.reconcileNormal(ctx, tc.helmReleaseProxy, clientMock, "", "", restConfig)
if tc.expectedError != "" {
g.Expect(err).To(HaveOccurred())
g.Expect(err).To(MatchError(tc.expectedError), err.Error())
Expand All @@ -330,7 +331,7 @@ func TestReconcileNormalWithCredentialRef(t *testing.T) {
name: "successfully install a Helm release",
helmReleaseProxy: defaultProxyWithCredentialRef.DeepCopy(),
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.InstallOrUpgradeHelmRelease(ctx, kubeconfig, "/tmp/oci-credentials-xyz.json", "", defaultProxyWithCredentialRef.Spec).Return(&helmRelease.Release{
c.InstallOrUpgradeHelmRelease(ctx, restConfig, "/tmp/oci-credentials-xyz.json", "", defaultProxyWithCredentialRef.Spec).Return(&helmRelease.Release{
Name: "test-release",
Version: 1,
Info: &helmRelease.Info{
Expand Down Expand Up @@ -370,7 +371,7 @@ func TestReconcileNormalWithCredentialRef(t *testing.T) {
Build(),
}

err := r.reconcileNormal(ctx, tc.helmReleaseProxy, clientMock, "/tmp/oci-credentials-xyz.json", "", kubeconfig)
err := r.reconcileNormal(ctx, tc.helmReleaseProxy, clientMock, "/tmp/oci-credentials-xyz.json", "", restConfig)
if tc.expectedError != "" {
g.Expect(err).To(HaveOccurred())
g.Expect(err).To(MatchError(tc.expectedError), err.Error())
Expand All @@ -396,7 +397,7 @@ func TestReconcileNormalWithACertificateRef(t *testing.T) {
name: "successfully install a Helm release",
helmReleaseProxy: defaultProxyWithCACertRef.DeepCopy(),
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.InstallOrUpgradeHelmRelease(ctx, kubeconfig, "", "/tmp/ca-xyz.crt", defaultProxyWithCACertRef.Spec).Return(&helmRelease.Release{
c.InstallOrUpgradeHelmRelease(ctx, restConfig, "", "/tmp/ca-xyz.crt", defaultProxyWithCACertRef.Spec).Return(&helmRelease.Release{
Name: "test-release",
Version: 1,
Info: &helmRelease.Info{
Expand Down Expand Up @@ -436,7 +437,7 @@ func TestReconcileNormalWithACertificateRef(t *testing.T) {
Build(),
}

err := r.reconcileNormal(ctx, tc.helmReleaseProxy, clientMock, "", "/tmp/ca-xyz.crt", kubeconfig)
err := r.reconcileNormal(ctx, tc.helmReleaseProxy, clientMock, "", "/tmp/ca-xyz.crt", restConfig)
if tc.expectedError != "" {
g.Expect(err).To(HaveOccurred())
g.Expect(err).To(MatchError(tc.expectedError), err.Error())
Expand All @@ -462,14 +463,14 @@ func TestReconcileDelete(t *testing.T) {
name: "successfully uninstall a Helm release",
helmReleaseProxy: defaultProxy.DeepCopy(),
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.GetHelmRelease(ctx, kubeconfig, defaultProxy.DeepCopy().Spec).Return(&helmRelease.Release{
c.GetHelmRelease(ctx, restConfig, defaultProxy.DeepCopy().Spec).Return(&helmRelease.Release{
Name: "test-release",
Version: 1,
Info: &helmRelease.Info{
Status: helmRelease.StatusDeployed,
},
}, nil).Times(1)
c.UninstallHelmRelease(ctx, kubeconfig, defaultProxy.DeepCopy().Spec).Return(&helmRelease.UninstallReleaseResponse{}, nil).Times(1)
c.UninstallHelmRelease(ctx, restConfig, defaultProxy.DeepCopy().Spec).Return(&helmRelease.UninstallReleaseResponse{}, nil).Times(1)
},
expect: func(g *WithT, hrp *addonsv1alpha1.HelmReleaseProxy) {
g.Expect(conditions.Has(hrp, addonsv1alpha1.HelmReleaseReadyCondition)).To(BeTrue())
Expand All @@ -484,7 +485,7 @@ func TestReconcileDelete(t *testing.T) {
name: "Helm release already uninstalled",
helmReleaseProxy: defaultProxy.DeepCopy(),
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.GetHelmRelease(ctx, kubeconfig, defaultProxy.DeepCopy().Spec).Return(nil, helmDriver.ErrReleaseNotFound).Times(1)
c.GetHelmRelease(ctx, restConfig, defaultProxy.DeepCopy().Spec).Return(nil, helmDriver.ErrReleaseNotFound).Times(1)
},
expect: func(g *WithT, hrp *addonsv1alpha1.HelmReleaseProxy) {
g.Expect(conditions.Has(hrp, addonsv1alpha1.HelmReleaseReadyCondition)).To(BeTrue())
Expand All @@ -499,7 +500,7 @@ func TestReconcileDelete(t *testing.T) {
name: "error attempting to get Helm release",
helmReleaseProxy: defaultProxy.DeepCopy(),
clientExpect: func(g *WithT, c *mocks.MockClientMockRecorder) {
c.GetHelmRelease(ctx, kubeconfig, defaultProxy.DeepCopy().Spec).Return(nil, errInternal).Times(1)
c.GetHelmRelease(ctx, restConfig, defaultProxy.DeepCopy().Spec).Return(nil, errInternal).Times(1)
},
expect: func(g *WithT, hrp *addonsv1alpha1.HelmReleaseProxy) {
g.Expect(conditions.Has(hrp, addonsv1alpha1.HelmReleaseReadyCondition)).To(BeTrue())
Expand Down Expand Up @@ -530,7 +531,7 @@ func TestReconcileDelete(t *testing.T) {
Build(),
}

err := r.reconcileDelete(ctx, tc.helmReleaseProxy, clientMock, kubeconfig)
err := r.reconcileDelete(ctx, tc.helmReleaseProxy, clientMock, restConfig)
if tc.expectedError != "" {
g.Expect(err).To(HaveOccurred())
g.Expect(err).To(MatchError(tc.expectedError), err.Error())
Expand Down
30 changes: 13 additions & 17 deletions controllers/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,21 +50,20 @@ import (
// http://onsi.github.io/ginkgo/ to learn more about Ginkgo.

var (
k8sClient client.Client
testEnv *envtest.Environment
k8sManager manager.Manager
ctx context.Context
cancel context.CancelFunc
helmClient *mocks.MockClient
kubeconfigGetter *mocks.MockGetter
k8sClient client.Client
testEnv *envtest.Environment
k8sManager manager.Manager
ctx context.Context
cancel context.CancelFunc
helmClient *mocks.MockClient
)

const (
timeout = time.Second * 10
interval = time.Millisecond * 250
)

func TestAPIs(t *testing.T) {
func TestControllers(t *testing.T) {
RegisterFailHandler(Fail)

RunSpecs(t, "Controller Suite")
Expand Down Expand Up @@ -128,12 +127,10 @@ var _ = BeforeSuite(func() {
Expect(k8sClient).NotTo(BeNil())

helmClient = mocks.NewMockClient(gomock.NewController(&TestReporter{}))
kubeconfigGetter = mocks.NewMockGetter(gomock.NewController(&TestReporter{}))

kubeconfigGetter.EXPECT().GetClusterKubeconfig(gomock.Any(), client.ObjectKeyFromObject(cluster1)).Return(kubeconfig, nil).AnyTimes()
helmClient.EXPECT().InstallOrUpgradeHelmRelease(gomock.Any(), kubeconfig, gomock.Any(), gomock.Any(), gomock.Any()).Return(helmReleaseDeployed, nil).AnyTimes()
helmClient.EXPECT().UninstallHelmRelease(gomock.Any(), kubeconfig, gomock.Any()).Return(&helmRelease.UninstallReleaseResponse{}, nil).AnyTimes()
helmClient.EXPECT().GetHelmRelease(gomock.Any(), kubeconfig, gomock.Any()).Return(&helmRelease.Release{}, nil).AnyTimes()
helmClient.EXPECT().InstallOrUpgradeHelmRelease(gomock.Any(), gomock.Any(), gomock.Any(), gomock.Any(), gomock.Any()).Return(helmReleaseDeployed, nil).AnyTimes()
helmClient.EXPECT().UninstallHelmRelease(gomock.Any(), gomock.Any(), gomock.Any()).Return(&helmRelease.UninstallReleaseResponse{}, nil).AnyTimes()
helmClient.EXPECT().GetHelmRelease(gomock.Any(), gomock.Any(), gomock.Any()).Return(&helmRelease.Release{}, nil).AnyTimes()

err = (&helmchartproxy.HelmChartProxyReconciler{
Client: k8sManager.GetClient(),
Expand All @@ -142,10 +139,9 @@ var _ = BeforeSuite(func() {
Expect(err).ToNot(HaveOccurred())

err = (&helmreleaseproxy.HelmReleaseProxyReconciler{
Client: k8sManager.GetClient(),
Scheme: k8sManager.GetScheme(),
KubeconfigGetter: kubeconfigGetter,
HelmClient: helmClient,
Client: k8sManager.GetClient(),
Scheme: k8sManager.GetScheme(),
HelmClient: helmClient,
}).SetupWithManager(ctx, k8sManager, controller.Options{})
Expect(err).ToNot(HaveOccurred())

Expand Down
Loading

0 comments on commit db42942

Please sign in to comment.