`get etcd local certs dir by module cache failed` when recreate cluster with kk v2.0.0-version(master)
Created by: tanguofu
What is version of KubeKey has the issue?
./output/kk version version.BuildInfo{Version:"latest+unreleased", GitCommit:"b5a41a02", GitTreeState:"dirty", GoVersion:"go1.16.11"}
What is your os environment?
centos 7.9
KubeKey config file
only a single node config
A clear and concise description of what happend.
./kk create cluster -f config-sample.yaml -y --debug
Relevant log output
14:36:03 CST success: [node1]
14:36:03 CST [CertsModule] Generate certs script
14:36:03 CST skipped: [node1]
14:36:03 CST [CertsModule] Generate OpenSSL config
14:36:03 CST skipped: [node1]
14:36:03 CST [CertsModule] Exec certs script
14:36:03 CST skipped: [node1]
14:36:03 CST [CertsModule] Synchronize certs file
14:36:03 CST message: [node1]
get etcd local certs dir by module cache failed
Additional information
it seem thatPrepare: &FirstETCDNode{Not: true}, in syncCertsFile should be Prepare: &new(FirstETCDNode) ?
execCertsScript := &task.RemoteTask{
Name: "ExecCertsScript",
Desc: "Exec certs script",
Hosts: c.Runtime.GetHostsByRole(common.ETCD),
Prepare: new(FirstETCDNode),
Action: new(ExecCertsScript),
Parallel: true,
Retry: 1,
}
syncCertsFile := &task.RemoteTask{
Name: "SyncCertsFile",
Desc: "Synchronize certs file",
Hosts: c.Runtime.GetHostsByRole(common.ETCD),
Prepare: &FirstETCDNode{Not: true},
Action: new(SyncCertsFile),
Parallel: true,
Retry: 1,
}
syncCertsToMaster := &task.RemoteTask{
Name: "SyncCertsFileToMaster",
Desc: "Synchronize certs file to master",
Hosts: c.Runtime.GetHostsByRole(common.Master),
Prepare: &common.OnlyETCD{Not: true},
Action: new(SyncCertsFile),
Parallel: true,
Retry: 1,
}