mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
etcdutl: address var-naming lint warnings
Signed-off-by: Ivan Valdes <ivan@vald.es>
This commit is contained in:
parent
c2a3ca62c7
commit
bc3f109572
@ -35,7 +35,7 @@ var (
|
||||
restoreCluster string
|
||||
restoreClusterToken string
|
||||
restoreDataDir string
|
||||
restoreWalDir string
|
||||
restoreWALDir string
|
||||
restorePeerURLs string
|
||||
restoreName string
|
||||
skipHashCheck bool
|
||||
@ -73,7 +73,7 @@ func NewSnapshotRestoreCommand() *cobra.Command {
|
||||
Run: snapshotRestoreCommandFunc,
|
||||
}
|
||||
cmd.Flags().StringVar(&restoreDataDir, "data-dir", "", "Path to the output data directory")
|
||||
cmd.Flags().StringVar(&restoreWalDir, "wal-dir", "", "Path to the WAL directory (use --data-dir if none given)")
|
||||
cmd.Flags().StringVar(&restoreWALDir, "wal-dir", "", "Path to the WAL directory (use --data-dir if none given)")
|
||||
cmd.Flags().StringVar(&restoreCluster, "initial-cluster", initialClusterFromName(defaultName), "Initial cluster configuration for restore bootstrap")
|
||||
cmd.Flags().StringVar(&restoreClusterToken, "initial-cluster-token", "etcd-cluster", "Initial cluster token for the etcd cluster during restore bootstrap")
|
||||
cmd.Flags().StringVar(&restorePeerURLs, "initial-advertise-peer-urls", defaultInitialAdvertisePeerURLs, "List of this member's peer URLs to advertise to the rest of the cluster")
|
||||
@ -106,14 +106,14 @@ func SnapshotStatusCommandFunc(cmd *cobra.Command, args []string) {
|
||||
}
|
||||
|
||||
func snapshotRestoreCommandFunc(_ *cobra.Command, args []string) {
|
||||
SnapshotRestoreCommandFunc(restoreCluster, restoreClusterToken, restoreDataDir, restoreWalDir,
|
||||
SnapshotRestoreCommandFunc(restoreCluster, restoreClusterToken, restoreDataDir, restoreWALDir,
|
||||
restorePeerURLs, restoreName, skipHashCheck, initialMmapSize, revisionBump, markCompacted, args)
|
||||
}
|
||||
|
||||
func SnapshotRestoreCommandFunc(restoreCluster string,
|
||||
restoreClusterToken string,
|
||||
restoreDataDir string,
|
||||
restoreWalDir string,
|
||||
restoreWALDir string,
|
||||
restorePeerURLs string,
|
||||
restoreName string,
|
||||
skipHashCheck bool,
|
||||
@ -136,7 +136,7 @@ func SnapshotRestoreCommandFunc(restoreCluster string,
|
||||
dataDir = restoreName + ".etcd"
|
||||
}
|
||||
|
||||
walDir := restoreWalDir
|
||||
walDir := restoreWALDir
|
||||
if walDir == "" {
|
||||
walDir = datadir.ToWALDir(dataDir)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user