kubeadm: add missing --config flag to mark-control-plane phase

pull/58/head
Lubomir I. Ivanov 2018-11-24 05:12:04 +02:00
parent 94759c165f
commit a1a7ecaab3
3 changed files with 3 additions and 2 deletions

View File

@ -31,7 +31,7 @@ const APIServerExtraArgs = "apiserver-extra-args"
// CertificatesDir flag sets the path where to save and read the certificates. // CertificatesDir flag sets the path where to save and read the certificates.
const CertificatesDir = "cert-dir" const CertificatesDir = "cert-dir"
// CfgPath flag sets the path to kubeadm config file. WARNING: Usage of a configuration file is experimental. // CfgPath flag sets the path to kubeadm config file.
const CfgPath = "config" const CfgPath = "config"
// ControllerManagerExtraArgs flag sets extra flags to pass to the Controller Manager or override default ones in form of <flagname>=<value>. // ControllerManagerExtraArgs flag sets extra flags to pass to the Controller Manager or override default ones in form of <flagname>=<value>.

View File

@ -33,7 +33,7 @@ func AddKubeConfigDirFlag(fs *pflag.FlagSet, kubeConfigDir *string) {
// AddConfigFlag adds the --config flag to the given flagset // AddConfigFlag adds the --config flag to the given flagset
func AddConfigFlag(fs *pflag.FlagSet, cfgPath *string) { func AddConfigFlag(fs *pflag.FlagSet, cfgPath *string) {
fs.StringVar(cfgPath, CfgPath, *cfgPath, "Path to kubeadm config file (WARNING: Usage of a configuration file is experimental).") fs.StringVar(cfgPath, CfgPath, *cfgPath, "Path to a kubeadm configuration file.")
} }
// AddIgnorePreflightErrorsFlag adds the --ignore-preflight-errors flag to the given flagset // AddIgnorePreflightErrorsFlag adds the --ignore-preflight-errors flag to the given flagset

View File

@ -50,6 +50,7 @@ func NewMarkControlPlanePhase() workflow.Phase {
Example: markControlPlaneExample, Example: markControlPlaneExample,
InheritFlags: []string{ InheritFlags: []string{
options.NodeName, options.NodeName,
options.CfgPath,
}, },
Run: runMarkControlPlane, Run: runMarkControlPlane,
} }