Skip to content

Commit 8caec9f

Browse files
1gtmEmruz Hossain
andauthored
[cherry-pick] Update flags: --username, --password to --username=, --password= (#1428)
/cherry-pick Signed-off-by: Emruz Hossain <emruz@appscode.com> Co-authored-by: Emruz Hossain <emruz@appscode.com>
1 parent 8014a99 commit 8caec9f

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

pkg/backup.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -348,8 +348,8 @@ func (opt *mongoOptions) backupMongoDB(targetRef api_v1beta1.TargetRef) (*restic
348348
}...)
349349
} else {
350350
adminCreds = []interface{}{
351-
"--username", string(appBindingSecret.Data[MongoUserKey]),
352-
"--password", string(appBindingSecret.Data[MongoPasswordKey]),
351+
fmt.Sprintf("--username=%s", appBindingSecret.Data[MongoUserKey]),
352+
fmt.Sprintf("--password=%s", appBindingSecret.Data[MongoPasswordKey]),
353353
"--authenticationDatabase", opt.authenticationDatabase,
354354
}
355355
}

pkg/restore.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -281,8 +281,8 @@ func (opt *mongoOptions) restoreMongoDB(targetRef api_v1beta1.TargetRef) (*resti
281281

282282
} else {
283283
adminCreds = []interface{}{
284-
"--username", string(appBindingSecret.Data[MongoUserKey]),
285-
"--password", string(appBindingSecret.Data[MongoPasswordKey]),
284+
fmt.Sprintf("--username=%s", appBindingSecret.Data[MongoUserKey]),
285+
fmt.Sprintf("--password=%s", appBindingSecret.Data[MongoPasswordKey]),
286286
"--authenticationDatabase", opt.authenticationDatabase,
287287
}
288288
}

0 commit comments

Comments
 (0)