[#604] Add MFADelete tests with reworked mfa.Storage implementation
All checks were successful
/ DCO (pull_request) Successful in 36s
/ Builds (pull_request) Successful in 1m38s
/ Vulncheck (pull_request) Successful in 1m37s
/ OCI image (pull_request) Successful in 2m16s
/ Lint (pull_request) Successful in 2m40s
/ Tests (pull_request) Successful in 1m26s
/ Vulncheck (push) Successful in 1m18s
/ Builds (push) Successful in 1m14s
/ OCI image (push) Successful in 2m0s
/ Lint (push) Successful in 2m14s
/ Tests (push) Successful in 1m35s
All checks were successful
/ DCO (pull_request) Successful in 36s
/ Builds (pull_request) Successful in 1m38s
/ Vulncheck (pull_request) Successful in 1m37s
/ OCI image (pull_request) Successful in 2m16s
/ Lint (pull_request) Successful in 2m40s
/ Tests (pull_request) Successful in 1m26s
/ Vulncheck (push) Successful in 1m18s
/ Builds (push) Successful in 1m14s
/ OCI image (push) Successful in 2m0s
/ Lint (push) Successful in 2m14s
/ Tests (push) Successful in 1m35s
Signed-off-by: Alex Vanin <a.vanin@yadro.com> Signed-off-by: Pavel Pogodaev <p.pogodaev@yadro.com>
This commit is contained in:
parent
0fc56cbfce
commit
7d6e20fdad
17 changed files with 440 additions and 233 deletions
|
@ -94,6 +94,17 @@ func (h *handler) PutBucketLifecycleHandler(w http.ResponseWriter, r *http.Reque
|
|||
return
|
||||
}
|
||||
|
||||
bktSettings, err := h.obj.GetBucketSettings(ctx, bktInfo)
|
||||
if err != nil {
|
||||
h.logAndSendError(ctx, w, "could not get bucket settings", reqInfo, err)
|
||||
return
|
||||
}
|
||||
|
||||
if bktSettings.MFADeleteEnabled() {
|
||||
h.logAndSendError(ctx, w, "failed to add", reqInfo, apierr.GetAPIError(apierr.ErrCannotPutLifecycleConfiguration))
|
||||
return
|
||||
}
|
||||
|
||||
networkInfo, err := h.obj.GetNetworkInfo(ctx)
|
||||
if err != nil {
|
||||
h.logAndSendError(ctx, w, "could not get network info", reqInfo, err)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue