diff --git a/cmd/flux/create_helmrelease.go b/cmd/flux/create_helmrelease.go index a741cca8..7660f005 100644 --- a/cmd/flux/create_helmrelease.go +++ b/cmd/flux/create_helmrelease.go @@ -1,5 +1,5 @@ /* -Copyright 2020 The Flux authors +Copyright 2024 The Flux authors Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -24,12 +24,6 @@ import ( "strings" "time" - "github.com/fluxcd/pkg/apis/meta" - "github.com/fluxcd/pkg/runtime/transform" - - "github.com/fluxcd/flux2/v2/internal/flags" - "github.com/fluxcd/flux2/v2/internal/utils" - "github.com/spf13/cobra" apiextensionsv1 "k8s.io/apiextensions-apiserver/pkg/apis/apiextensions/v1" "k8s.io/apimachinery/pkg/api/errors" @@ -39,7 +33,12 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client" "sigs.k8s.io/yaml" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" + "github.com/fluxcd/pkg/apis/meta" + "github.com/fluxcd/pkg/runtime/transform" + + "github.com/fluxcd/flux2/v2/internal/flags" + "github.com/fluxcd/flux2/v2/internal/utils" ) var createHelmReleaseCmd = &cobra.Command{ diff --git a/cmd/flux/create_kustomization.go b/cmd/flux/create_kustomization.go index aa3a73a7..6c662928 100644 --- a/cmd/flux/create_kustomization.go +++ b/cmd/flux/create_kustomization.go @@ -29,7 +29,7 @@ import ( "k8s.io/apimachinery/pkg/util/wait" "sigs.k8s.io/controller-runtime/pkg/client" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" kustomizev1 "github.com/fluxcd/kustomize-controller/api/v1" "github.com/fluxcd/pkg/apis/meta" diff --git a/cmd/flux/delete_helmrelease.go b/cmd/flux/delete_helmrelease.go index a182c0a6..25d262ac 100644 --- a/cmd/flux/delete_helmrelease.go +++ b/cmd/flux/delete_helmrelease.go @@ -19,7 +19,7 @@ package main import ( "github.com/spf13/cobra" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" ) var deleteHelmReleaseCmd = &cobra.Command{ diff --git a/cmd/flux/events.go b/cmd/flux/events.go index e4774042..5ac5afd2 100644 --- a/cmd/flux/events.go +++ b/cmd/flux/events.go @@ -39,7 +39,7 @@ import ( cmdutil "k8s.io/kubectl/pkg/cmd/util" "sigs.k8s.io/controller-runtime/pkg/client" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" autov1 "github.com/fluxcd/image-automation-controller/api/v1beta2" imagev1 "github.com/fluxcd/image-reflector-controller/api/v1beta2" kustomizev1 "github.com/fluxcd/kustomize-controller/api/v1" diff --git a/cmd/flux/events_test.go b/cmd/flux/events_test.go index cb27e3eb..1964b867 100644 --- a/cmd/flux/events_test.go +++ b/cmd/flux/events_test.go @@ -78,7 +78,7 @@ spec: timeout: 1m0s url: ssh://git@github.com/example/repo --- -apiVersion: helm.toolkit.fluxcd.io/v2beta2 +apiVersion: helm.toolkit.fluxcd.io/v2 kind: HelmRelease metadata: name: podinfo diff --git a/cmd/flux/export_helmrelease.go b/cmd/flux/export_helmrelease.go index b55df13b..375722b1 100644 --- a/cmd/flux/export_helmrelease.go +++ b/cmd/flux/export_helmrelease.go @@ -20,7 +20,7 @@ import ( "github.com/spf13/cobra" metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" ) var exportHelmReleaseCmd = &cobra.Command{ diff --git a/cmd/flux/get_all.go b/cmd/flux/get_all.go index 7a40466b..69122ffd 100644 --- a/cmd/flux/get_all.go +++ b/cmd/flux/get_all.go @@ -20,7 +20,7 @@ import ( "github.com/spf13/cobra" apimeta "k8s.io/apimachinery/pkg/api/meta" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" kustomizev1 "github.com/fluxcd/kustomize-controller/api/v1" notificationv1 "github.com/fluxcd/notification-controller/api/v1" notificationv1b3 "github.com/fluxcd/notification-controller/api/v1beta3" diff --git a/cmd/flux/get_helmrelease.go b/cmd/flux/get_helmrelease.go index 034d11a6..4e1157b5 100644 --- a/cmd/flux/get_helmrelease.go +++ b/cmd/flux/get_helmrelease.go @@ -25,7 +25,7 @@ import ( "golang.org/x/text/language" "k8s.io/apimachinery/pkg/runtime" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" ) var getHelmReleaseCmd = &cobra.Command{ diff --git a/cmd/flux/helmrelease.go b/cmd/flux/helmrelease.go index d01d04c3..5b562b2c 100644 --- a/cmd/flux/helmrelease.go +++ b/cmd/flux/helmrelease.go @@ -19,7 +19,7 @@ package main import ( "sigs.k8s.io/controller-runtime/pkg/client" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" ) // helmv2.HelmRelease diff --git a/cmd/flux/reconcile.go b/cmd/flux/reconcile.go index b2e74105..c37f3d32 100644 --- a/cmd/flux/reconcile.go +++ b/cmd/flux/reconcile.go @@ -31,7 +31,7 @@ import ( "k8s.io/client-go/util/retry" "sigs.k8s.io/controller-runtime/pkg/client" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" "github.com/fluxcd/pkg/apis/meta" "github.com/fluxcd/flux2/v2/internal/utils" diff --git a/cmd/flux/reconcile_helmrelease.go b/cmd/flux/reconcile_helmrelease.go index 2d5586c2..c004afb1 100644 --- a/cmd/flux/reconcile_helmrelease.go +++ b/cmd/flux/reconcile_helmrelease.go @@ -22,7 +22,7 @@ import ( "github.com/spf13/cobra" "k8s.io/apimachinery/pkg/types" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" sourcev1 "github.com/fluxcd/source-controller/api/v1" ) diff --git a/cmd/flux/resume_helmrelease.go b/cmd/flux/resume_helmrelease.go index ecccaf46..47e68767 100644 --- a/cmd/flux/resume_helmrelease.go +++ b/cmd/flux/resume_helmrelease.go @@ -21,7 +21,7 @@ import ( "github.com/spf13/cobra" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" ) var resumeHrCmd = &cobra.Command{ diff --git a/cmd/flux/stats.go b/cmd/flux/stats.go index 1d58a730..08ef3294 100644 --- a/cmd/flux/stats.go +++ b/cmd/flux/stats.go @@ -27,7 +27,7 @@ import ( "sigs.k8s.io/controller-runtime/pkg/client" "github.com/fluxcd/cli-utils/pkg/kstatus/status" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" autov1 "github.com/fluxcd/image-automation-controller/api/v1beta2" imagev1 "github.com/fluxcd/image-reflector-controller/api/v1beta2" kustomizev1 "github.com/fluxcd/kustomize-controller/api/v1" diff --git a/cmd/flux/suspend_helmrelease.go b/cmd/flux/suspend_helmrelease.go index b4c3eb8f..c815b1b4 100644 --- a/cmd/flux/suspend_helmrelease.go +++ b/cmd/flux/suspend_helmrelease.go @@ -19,7 +19,7 @@ package main import ( "github.com/spf13/cobra" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" ) var suspendHrCmd = &cobra.Command{ diff --git a/cmd/flux/testdata/export/helm-release.yaml b/cmd/flux/testdata/export/helm-release.yaml index c7aceaf1..cabd8db5 100644 --- a/cmd/flux/testdata/export/helm-release.yaml +++ b/cmd/flux/testdata/export/helm-release.yaml @@ -1,5 +1,5 @@ --- -apiVersion: helm.toolkit.fluxcd.io/v2beta2 +apiVersion: helm.toolkit.fluxcd.io/v2 kind: HelmRelease metadata: name: flux-system diff --git a/cmd/flux/testdata/export/objects.yaml b/cmd/flux/testdata/export/objects.yaml index 40bac8d5..6a0c74c7 100644 --- a/cmd/flux/testdata/export/objects.yaml +++ b/cmd/flux/testdata/export/objects.yaml @@ -138,7 +138,7 @@ spec: name: podinfo version: '*' --- -apiVersion: helm.toolkit.fluxcd.io/v2beta2 +apiVersion: helm.toolkit.fluxcd.io/v2 kind: HelmRelease metadata: name: flux-system diff --git a/cmd/flux/testdata/trace/deployment.yaml b/cmd/flux/testdata/trace/deployment.yaml index a71fbd8a..4e28b8e9 100644 --- a/cmd/flux/testdata/trace/deployment.yaml +++ b/cmd/flux/testdata/trace/deployment.yaml @@ -34,7 +34,7 @@ spec: command: [ "echo hello world" ] image: busybox --- -apiVersion: helm.toolkit.fluxcd.io/v2beta2 +apiVersion: helm.toolkit.fluxcd.io/v2 kind: HelmRelease metadata: labels: diff --git a/cmd/flux/testdata/trace/helmrelease-oci.yaml b/cmd/flux/testdata/trace/helmrelease-oci.yaml index 0fc7b6c4..edd54dd1 100644 --- a/cmd/flux/testdata/trace/helmrelease-oci.yaml +++ b/cmd/flux/testdata/trace/helmrelease-oci.yaml @@ -9,7 +9,7 @@ kind: Namespace metadata: name: {{ .ns }} --- -apiVersion: helm.toolkit.fluxcd.io/v2beta2 +apiVersion: helm.toolkit.fluxcd.io/v2 kind: HelmRelease metadata: labels: diff --git a/cmd/flux/testdata/trace/helmrelease.yaml b/cmd/flux/testdata/trace/helmrelease.yaml index 8c029cde..98cdf5b2 100644 --- a/cmd/flux/testdata/trace/helmrelease.yaml +++ b/cmd/flux/testdata/trace/helmrelease.yaml @@ -9,7 +9,7 @@ kind: Namespace metadata: name: {{ .ns }} --- -apiVersion: helm.toolkit.fluxcd.io/v2beta2 +apiVersion: helm.toolkit.fluxcd.io/v2 kind: HelmRelease metadata: labels: diff --git a/cmd/flux/trace.go b/cmd/flux/trace.go index 7014bead..a62e9a52 100644 --- a/cmd/flux/trace.go +++ b/cmd/flux/trace.go @@ -33,7 +33,7 @@ import ( "k8s.io/cli-runtime/pkg/resource" "sigs.k8s.io/controller-runtime/pkg/client" - helmv2 "github.com/fluxcd/helm-controller/api/v2beta2" + helmv2 "github.com/fluxcd/helm-controller/api/v2" kustomizev1 "github.com/fluxcd/kustomize-controller/api/v1" fluxmeta "github.com/fluxcd/pkg/apis/meta" "github.com/fluxcd/pkg/oci" @@ -64,7 +64,7 @@ You can also trace multiple objects with different resource kinds using