From f3cc194f4136ba138f347fe32c8976f8a6937955 Mon Sep 17 00:00:00 2001 From: cuisongliu Date: Thu, 15 Aug 2019 17:43:34 +0800 Subject: [PATCH] fix pk bug --- cmd/install.go | 2 +- cmd/uninstall.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/install.go b/cmd/install.go index 98ff76e..6c5e1ae 100644 --- a/cmd/install.go +++ b/cmd/install.go @@ -37,7 +37,7 @@ func init() { // Here you will define your flags and configuration settings. installCmd.Flags().StringVar(&command.User, "user", "root", "servers user name for ssh") installCmd.Flags().StringVar(&command.Passwd, "passwd", "admin", "servers user password for ssh") - installCmd.Flags().StringVar(&command.PrivateKeyFile, "pk", "/root/.ssh/id_rsa", "servers user private key file for ssh") + installCmd.Flags().StringVar(&command.PrivateKeyFile, "pk", "", "servers user private key file for ssh") installCmd.Flags().StringSliceVar(&install.Hosts, "host", []string{}, "container install hosts") installCmd.Flags().StringSliceVar(&command.RegistryArr, "registry", []string{"127.0.0.1"}, "container's registry ip") diff --git a/cmd/uninstall.go b/cmd/uninstall.go index 70545df..c829339 100644 --- a/cmd/uninstall.go +++ b/cmd/uninstall.go @@ -35,7 +35,7 @@ func init() { rootCmd.AddCommand(uninstallCmd) uninstallCmd.Flags().StringVar(&command.User, "user", "root", "servers user name for ssh") uninstallCmd.Flags().StringVar(&command.Passwd, "passwd", "admin", "servers user password for ssh") - uninstallCmd.Flags().StringVar(&command.PrivateKeyFile, "pk", "/root/.ssh/id_rsa", "servers user private key file for ssh") + uninstallCmd.Flags().StringVar(&command.PrivateKeyFile, "pk", "", "servers user private key file for ssh") uninstallCmd.Flags().StringSliceVar(&install.Hosts, "host", []string{}, "install hosts") uninstallCmd.Flags().StringVar(&command.Lib, "lib", "", "store location,default : docker is /var/lib/docker , containerd is /var/lib/containerd ")