rc: validate Daemon option is not set when mounting a volume via RC - fixes #6469

This commit is contained in:
Isaac Aymerich 2022-10-12 13:07:48 +02:00 committed by GitHub
parent cf0bf159ab
commit 3f804224f4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions

View File

@ -97,6 +97,10 @@ func mountRc(ctx context.Context, in rc.Params) (out rc.Params, err error) {
return nil, err
}
if mountOpt.Daemon {
return nil, errors.New("Daemon Option not supported over the API")
}
mountType, err := in.GetString("mountType")
mountMu.Lock()