Skip to content

"rsync for cloud storage" - Google Drive, S3, Dropbox, Backblaze B2, One Drive, Swift, Hubic, Wasabi, Google Cloud Storage, Azure Blob, Azure Files, Yandex Files

s3: backend restore command to skip non-GLACIER objects

Vincent Murphy319ac225e428
diff --git a/backend/s3/s3.go b/backend/s3/s3.go
index d8ba92724..89ac51b3d 100644
--- a/backend/s3/s3.go
+++ b/backend/s3/s3.go
@@ -3338,6 +3338,10 @@ func (f *Fs) Command(ctx context.Context, name string, arg []string, opt map[str
st.Status = "Not an S3 object"
return
}
+ if o.storageClass != "GLACIER" && o.storageClass != "DEEP_ARCHIVE" {
+ st.Status = "Not GLACIER or DEEP_ARCHIVE storage class"
+ return
+ }
bucket, bucketPath := o.split()
reqCopy := req
reqCopy.Bucket = &bucket