mirror of
https://git.vectorsigma.ru/public/k3s.git
synced 2026-07-28 22:29:32 +00:00
Add ability to perform an etcd on-demand snapshot via cli (#2819)
* add ability to perform an etcd on-demand snapshot via cli
This commit is contained in:
@@ -42,7 +42,7 @@ const (
|
||||
ControlPlaneRoleLabelKey = "node-role.kubernetes.io/control-plane"
|
||||
)
|
||||
|
||||
func resolveDataDir(dataDir string) (string, error) {
|
||||
func ResolveDataDir(dataDir string) (string, error) {
|
||||
dataDir, err := datadir.Resolve(dataDir)
|
||||
return filepath.Join(dataDir, "server"), err
|
||||
}
|
||||
@@ -322,7 +322,7 @@ func setupDataDirAndChdir(config *config.Control) error {
|
||||
err error
|
||||
)
|
||||
|
||||
config.DataDir, err = resolveDataDir(config.DataDir)
|
||||
config.DataDir, err = ResolveDataDir(config.DataDir)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user