kubeadm: remove the deprecated GA CoreDNS feature-gate

The CoreDNS GA feature-gate in kubeadm was deprecated since 1.13.
The k8s policy is to remove the gate 2 releases after it transitions
to GA:
https://kubernetes.io/docs/reference/using-api/deprecation-policy/#deprecation

We kept it around for longer to prevent existing setups from breaking
as it caused minimal maintenance overhead.
This commit is contained in:
Lubomir I. Ivanov 2020-01-21 02:42:35 +02:00
parent e6b5194ec1
commit 261f26075c
4 changed files with 0 additions and 21 deletions

View File

@ -85,7 +85,6 @@ go_test(
"//cmd/kubeadm/app/apis/output/v1alpha1:go_default_library", "//cmd/kubeadm/app/apis/output/v1alpha1:go_default_library",
"//cmd/kubeadm/app/cmd/options:go_default_library", "//cmd/kubeadm/app/cmd/options:go_default_library",
"//cmd/kubeadm/app/constants:go_default_library", "//cmd/kubeadm/app/constants:go_default_library",
"//cmd/kubeadm/app/features:go_default_library",
"//cmd/kubeadm/app/util:go_default_library", "//cmd/kubeadm/app/util:go_default_library",
"//cmd/kubeadm/app/util/config:go_default_library", "//cmd/kubeadm/app/util/config:go_default_library",
"//cmd/kubeadm/app/util/output:go_default_library", "//cmd/kubeadm/app/util/output:go_default_library",

View File

@ -17,7 +17,6 @@ limitations under the License.
package cmd package cmd
import ( import (
"fmt"
"io/ioutil" "io/ioutil"
"os" "os"
"path/filepath" "path/filepath"
@ -25,7 +24,6 @@ import (
"k8s.io/apimachinery/pkg/util/sets" "k8s.io/apimachinery/pkg/util/sets"
"k8s.io/kubernetes/cmd/kubeadm/app/cmd/options" "k8s.io/kubernetes/cmd/kubeadm/app/cmd/options"
"k8s.io/kubernetes/cmd/kubeadm/app/features"
) )
const ( const (
@ -86,13 +84,6 @@ func TestNewInitData(t *testing.T) {
}, },
expectError: true, expectError: true,
}, },
{
name: "fail if deprecated feature gates are set",
flags: map[string]string{
options.FeatureGatesString: fmt.Sprintf("%s=true", features.CoreDNS),
},
expectError: true,
},
{ {
name: "fails if invalid preflight checks are provided", name: "fails if invalid preflight checks are provided",
flags: map[string]string{ flags: map[string]string{

View File

@ -28,19 +28,12 @@ import (
) )
const ( const (
// CoreDNS is GA in v1.11
CoreDNS = "CoreDNS"
// IPv6DualStack is expected to be alpha in v1.16 // IPv6DualStack is expected to be alpha in v1.16
IPv6DualStack = "IPv6DualStack" IPv6DualStack = "IPv6DualStack"
) )
var coreDNSMessage = "featureGates:CoreDNS has been removed in v1.13\n" +
"\tUse kubeadm-config to select which DNS addon to install."
// InitFeatureGates are the default feature gates for the init command // InitFeatureGates are the default feature gates for the init command
var InitFeatureGates = FeatureList{ var InitFeatureGates = FeatureList{
CoreDNS: {FeatureSpec: featuregate.FeatureSpec{Default: true, PreRelease: featuregate.Deprecated}, HiddenInHelpText: true, DeprecationMessage: coreDNSMessage},
IPv6DualStack: {FeatureSpec: featuregate.FeatureSpec{Default: false, PreRelease: featuregate.Alpha}}, IPv6DualStack: {FeatureSpec: featuregate.FeatureSpec{Default: false, PreRelease: featuregate.Alpha}},
} }

View File

@ -352,10 +352,6 @@ func TestCmdInitFeatureGates(t *testing.T) {
name: "no feature gates passed", name: "no feature gates passed",
args: "", args: "",
}, },
{
name: "feature gate CoreDNS=true",
args: "--feature-gates=CoreDNS=true",
},
{ {
name: "feature gate IPv6DualStack=true", name: "feature gate IPv6DualStack=true",
args: "--feature-gates=IPv6DualStack=true", args: "--feature-gates=IPv6DualStack=true",