mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-25 20:53:33 +00:00
Merge pull request #70023 from SataQiu/fix-20181019
clean up redundant code for kubeadm join
This commit is contained in:
commit
7cbb999518
@ -447,11 +447,6 @@ func (j *Join) CheckIfReadyForAdditionalControlPlane(initConfiguration *kubeadma
|
|||||||
// PrepareForHostingControlPlane makes all preparation activities require for a node hosting a new control plane instance
|
// PrepareForHostingControlPlane makes all preparation activities require for a node hosting a new control plane instance
|
||||||
func (j *Join) PrepareForHostingControlPlane(initConfiguration *kubeadmapi.InitConfiguration) error {
|
func (j *Join) PrepareForHostingControlPlane(initConfiguration *kubeadmapi.InitConfiguration) error {
|
||||||
|
|
||||||
// Creates the admin kubeconfig file for the admin and for kubeadm itself.
|
|
||||||
if err := kubeconfigphase.CreateAdminKubeConfigFile(kubeadmconstants.KubernetesDir, initConfiguration); err != nil {
|
|
||||||
return errors.Wrap(err, "error generating the admin kubeconfig file")
|
|
||||||
}
|
|
||||||
|
|
||||||
// Generate missing certificates (if any)
|
// Generate missing certificates (if any)
|
||||||
if err := certsphase.CreatePKIAssets(initConfiguration); err != nil {
|
if err := certsphase.CreatePKIAssets(initConfiguration); err != nil {
|
||||||
return err
|
return err
|
||||||
|
Loading…
Reference in New Issue
Block a user