Add option to print machine creds (#1149)
* Add option to print machine creds Signed-off-by: Shivam Sandbhor <shivam.sandbhor@gmail.com>
This commit is contained in:
parent
a6e405422c
commit
c109e0e7dd
1 changed files with 1 additions and 1 deletions
|
@ -256,7 +256,7 @@ cscli machines add MyTestMachine --password MyPassword
|
|||
if err != nil {
|
||||
log.Fatalf("unable to marshal api credentials: %s", err)
|
||||
}
|
||||
if dumpFile != "" {
|
||||
if dumpFile != "" && dumpFile != "-" {
|
||||
err = ioutil.WriteFile(dumpFile, apiConfigDump, 0644)
|
||||
if err != nil {
|
||||
log.Fatalf("write api credentials in '%s' failed: %s", dumpFile, err)
|
||||
|
|
Loading…
Add table
Reference in a new issue