mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-29 22:46:12 +00:00
Deprecation of the kubeamd config upload command
This also deprecated all the sub commands.
This commit is contained in:
parent
4d3d153210
commit
c55eaa9b5a
@ -263,12 +263,14 @@ func NewCmdConfigMigrate(out io.Writer) *cobra.Command {
|
|||||||
return cmd
|
return cmd
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewCmdConfigUpload returns cobra.Command for "kubeadm config upload" command
|
// NewCmdConfigUpload (Deprecated) returns cobra.Command for "kubeadm config upload" command
|
||||||
|
// Deprecated: please see kubeadm init phase upload-config
|
||||||
func NewCmdConfigUpload(out io.Writer, kubeConfigFile *string) *cobra.Command {
|
func NewCmdConfigUpload(out io.Writer, kubeConfigFile *string) *cobra.Command {
|
||||||
cmd := &cobra.Command{
|
cmd := &cobra.Command{
|
||||||
Use: "upload",
|
Deprecated: "please see kubeadm init phase upload-config",
|
||||||
Short: "Upload configuration about the current state, so that 'kubeadm upgrade' can later know how to configure the upgraded cluster",
|
Use: "upload",
|
||||||
RunE: cmdutil.SubCmdRunE("upload"),
|
Short: "Upload configuration about the current state, so that 'kubeadm upgrade' can later know how to configure the upgraded cluster",
|
||||||
|
RunE: cmdutil.SubCmdRunE("upload"),
|
||||||
}
|
}
|
||||||
|
|
||||||
cmd.AddCommand(NewCmdConfigUploadFromFile(out, kubeConfigFile))
|
cmd.AddCommand(NewCmdConfigUploadFromFile(out, kubeConfigFile))
|
||||||
@ -299,11 +301,13 @@ func NewCmdConfigView(out io.Writer, kubeConfigFile *string) *cobra.Command {
|
|||||||
|
|
||||||
// NewCmdConfigUploadFromFile verifies given Kubernetes config file and returns cobra.Command for
|
// NewCmdConfigUploadFromFile verifies given Kubernetes config file and returns cobra.Command for
|
||||||
// "kubeadm config upload from-file" command
|
// "kubeadm config upload from-file" command
|
||||||
|
// Deprecated: please see kubeadm init phase upload-config
|
||||||
func NewCmdConfigUploadFromFile(out io.Writer, kubeConfigFile *string) *cobra.Command {
|
func NewCmdConfigUploadFromFile(out io.Writer, kubeConfigFile *string) *cobra.Command {
|
||||||
var cfgPath string
|
var cfgPath string
|
||||||
cmd := &cobra.Command{
|
cmd := &cobra.Command{
|
||||||
Use: "from-file",
|
Deprecated: "please see kubeadm init phase upload-config",
|
||||||
Short: "Upload a configuration file to the in-cluster ConfigMap for kubeadm configuration",
|
Use: "from-file",
|
||||||
|
Short: "Upload a configuration file to the in-cluster ConfigMap for kubeadm configuration",
|
||||||
Long: fmt.Sprintf(dedent.Dedent(`
|
Long: fmt.Sprintf(dedent.Dedent(`
|
||||||
Using this command, you can upload configuration to the ConfigMap in the cluster using the same config file you gave to 'kubeadm init'.
|
Using this command, you can upload configuration to the ConfigMap in the cluster using the same config file you gave to 'kubeadm init'.
|
||||||
If you initialized your cluster using a v1.7.x or lower kubeadm client and used the --config option, you need to run this command with the
|
If you initialized your cluster using a v1.7.x or lower kubeadm client and used the --config option, you need to run this command with the
|
||||||
@ -335,6 +339,7 @@ func NewCmdConfigUploadFromFile(out io.Writer, kubeConfigFile *string) *cobra.Co
|
|||||||
}
|
}
|
||||||
|
|
||||||
// NewCmdConfigUploadFromFlags returns cobra.Command for "kubeadm config upload from-flags" command
|
// NewCmdConfigUploadFromFlags returns cobra.Command for "kubeadm config upload from-flags" command
|
||||||
|
// Deprecated: please see kubeadm init phase upload-config
|
||||||
func NewCmdConfigUploadFromFlags(out io.Writer, kubeConfigFile *string) *cobra.Command {
|
func NewCmdConfigUploadFromFlags(out io.Writer, kubeConfigFile *string) *cobra.Command {
|
||||||
cfg := &kubeadmapiv1beta2.InitConfiguration{}
|
cfg := &kubeadmapiv1beta2.InitConfiguration{}
|
||||||
kubeadmscheme.Scheme.Default(cfg)
|
kubeadmscheme.Scheme.Default(cfg)
|
||||||
@ -342,8 +347,9 @@ func NewCmdConfigUploadFromFlags(out io.Writer, kubeConfigFile *string) *cobra.C
|
|||||||
var featureGatesString string
|
var featureGatesString string
|
||||||
|
|
||||||
cmd := &cobra.Command{
|
cmd := &cobra.Command{
|
||||||
Use: "from-flags",
|
Deprecated: "please see kubeadm init phase upload-config",
|
||||||
Short: "Create the in-cluster configuration file for the first time from using flags",
|
Use: "from-flags",
|
||||||
|
Short: "Create the in-cluster configuration file for the first time from using flags",
|
||||||
Long: fmt.Sprintf(dedent.Dedent(`
|
Long: fmt.Sprintf(dedent.Dedent(`
|
||||||
Using this command, you can upload configuration to the ConfigMap in the cluster using the same flags you gave to 'kubeadm init'.
|
Using this command, you can upload configuration to the ConfigMap in the cluster using the same flags you gave to 'kubeadm init'.
|
||||||
If you initialized your cluster using a v1.7.x or lower kubeadm client and set certain flags, you need to run this command with the
|
If you initialized your cluster using a v1.7.x or lower kubeadm client and set certain flags, you need to run this command with the
|
||||||
|
Loading…
Reference in New Issue
Block a user