diff --git a/pkg/machinery/interfaces.go b/pkg/machinery/interfaces.go index 8e285339119..cf28d9c8fb6 100644 --- a/pkg/machinery/interfaces.go +++ b/pkg/machinery/interfaces.go @@ -83,6 +83,14 @@ type HasMultiGroup interface { InjectMultiGroup(bool) } +// Deprecated: The ComponentConfig has been deprecated in the Controller-Runtime since its version 0.15.0. +// Fur further information see: https://github.com/kubernetes-sigs/controller-runtime/issues/895 +// Moreover, it has undergone breaking changes and is no longer functioning as intended. +// As a result, Kubebuilder, which heavily relies on the Controller Runtime, has also deprecated this feature, +// no longer guaranteeing its functionality from version 3.11.0 onwards. +// +// Please, be aware that it will force Kubebuilder remove this option soon in future release. +// // HasComponentConfig allows the component-config flag to be used on a template type HasComponentConfig interface { // InjectComponentConfig sets the template component-config flag diff --git a/pkg/machinery/mixins.go b/pkg/machinery/mixins.go index 1b38f8da4c8..a4045f56e52 100644 --- a/pkg/machinery/mixins.go +++ b/pkg/machinery/mixins.go @@ -129,6 +129,14 @@ func (m *MultiGroupMixin) InjectMultiGroup(flag bool) { m.MultiGroup = flag } +// Deprecated: The ComponentConfig has been deprecated in the Controller-Runtime since its version 0.15.0. +// Fur further information see: https://github.com/kubernetes-sigs/controller-runtime/issues/895 +// Moreover, it has undergone breaking changes and is no longer functioning as intended. +// As a result, Kubebuilder, which heavily relies on the Controller Runtime, has also deprecated this feature, +// no longer guaranteeing its functionality from version 3.11.0 onwards. +// +// Please, be aware that it will force Kubebuilder remove this option soon in future release. +// // ComponentConfigMixin provides templates with a injectable component-config flag field type ComponentConfigMixin struct { // ComponentConfig is the component-config flag diff --git a/pkg/plugins/common/kustomize/v2/init.go b/pkg/plugins/common/kustomize/v2/init.go index 2d40b4dcd50..fbe022ce016 100644 --- a/pkg/plugins/common/kustomize/v2/init.go +++ b/pkg/plugins/common/kustomize/v2/init.go @@ -62,6 +62,11 @@ func (p *initSubcommand) BindFlags(fs *pflag.FlagSet) { fs.StringVar(&p.name, "project-name", "", "name of this project") fs.BoolVar(&p.componentConfig, "component-config", false, "create a versioned ComponentConfig file, may be 'true' or 'false'") + _ = fs.MarkDeprecated("component-config", "the ComponentConfig has been deprecated in the "+ + "Controller-Runtime since its version 0.15.0. Moreover, it has undergone breaking changes and is no longer "+ + "functioning as intended. As a result, this tool, which heavily relies on the Controller Runtime, "+ + "has also deprecated this feature, no longer guaranteeing its functionality from version 3.11.0 onwards. "+ + "You can find additional details on https://github.com/kubernetes-sigs/controller-runtime/issues/895.") } func (p *initSubcommand) InjectConfig(c config.Config) error {