diff --git a/README.md b/README.md index 307d95342..1f3ca3dfb 100644 --- a/README.md +++ b/README.md @@ -29,6 +29,7 @@ Rclone *("rsync for cloud storage")* is a command-line program to sync files and * Box [:page_facing_up:](https://rclone.org/box/) * Ceph [:page_facing_up:](https://rclone.org/s3/#ceph) * China Mobile Ecloud Elastic Object Storage (EOS) [:page_facing_up:](https://rclone.org/s3/#china-mobile-ecloud-eos) + * Arvan Cloud Object Storage (AOS) [:page_facing_up:](https://rclone.org/s3/#arvan-cloud-object-storage-aos) * Citrix ShareFile [:page_facing_up:](https://rclone.org/sharefile/) * DigitalOcean Spaces [:page_facing_up:](https://rclone.org/s3/#digitalocean-spaces) * Digi Storage [:page_facing_up:](https://rclone.org/koofr/#digi-storage) diff --git a/backend/s3/s3.go b/backend/s3/s3.go index 461e48ee9..afc9b36f5 100644 --- a/backend/s3/s3.go +++ b/backend/s3/s3.go @@ -58,7 +58,7 @@ import ( func init() { fs.Register(&fs.RegInfo{ Name: "s3", - Description: "Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, China Mobile, Digital Ocean, Dreamhost, IBM COS, Lyve Cloud, Minio, Netease, RackCorp, Scaleway, SeaweedFS, StackPath, Storj, Tencent COS and Wasabi", + Description: "Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, China Mobile, ArvanCloud, Digital Ocean, Dreamhost, IBM COS, Lyve Cloud, Minio, Netease, RackCorp, Scaleway, SeaweedFS, StackPath, Storj, Tencent COS and Wasabi", NewFs: NewFs, CommandHelp: commandHelp, Options: []fs.Option{{ @@ -78,6 +78,9 @@ func init() { }, { Value: "ChinaMobile", Help: "China Mobile Ecloud Elastic Object Storage (EOS)", + }, { + Value: "ArvanCloud", + Help: "Arvan Cloud Object Storage (AOS)", }, { Value: "DigitalOcean", Help: "Digital Ocean Spaces", @@ -297,7 +300,7 @@ func init() { }, { Name: "region", Help: "Region to connect to.\n\nLeave blank if you are using an S3 clone and you don't have a region.", - Provider: "!AWS,Alibaba,ChinaMobile,RackCorp,Scaleway,Storj,TencentCOS", + Provider: "!AWS,Alibaba,ChinaMobile,ArvanCloud,RackCorp,Scaleway,Storj,TencentCOS", Examples: []fs.OptionExample{{ Value: "", Help: "Use this if unsure.\nWill use v4 signatures and an empty region.", @@ -405,6 +408,18 @@ func init() { Value: "eos-anhui-1.cmecloud.cn", Help: "Anhui China (Huainan)", }}, + }, { + // ArvanCloud endpoints: https://www.arvancloud.com/en/products/cloud-storage + Name: "endpoint", + Help: "Endpoint for Arvan Cloud Object Storage (AOS) API.", + Provider: "ArvanCloud", + Examples: []fs.OptionExample{{ + Value: "s3.ir-thr-at1.arvanstorage.com", + Help: "The default endpoint - a good choice if you are unsure.\nTehran Iran (Asiatech)", + }, { + Value: "s3.ir-tbz-sh1.arvanstorage.com", + Help: "Tabriz Iran (Shahriar)", + }}, }, { Name: "endpoint", Help: "Endpoint for IBM COS S3 API.\n\nSpecify if using an IBM COS On Premise.", @@ -845,7 +860,7 @@ func init() { }, { Name: "endpoint", Help: "Endpoint for S3 API.\n\nRequired when using an S3 clone.", - Provider: "!AWS,IBMCOS,TencentCOS,Alibaba,ChinaMobile,Scaleway,StackPath,Storj,RackCorp", + Provider: "!AWS,IBMCOS,TencentCOS,Alibaba,ChinaMobile,ArvanCloud,Scaleway,StackPath,Storj,RackCorp", Examples: []fs.OptionExample{{ Value: "objects-us-east-1.dream.io", Help: "Dream Objects endpoint", @@ -898,6 +913,10 @@ func init() { Value: "s3.ap-northeast-2.wasabisys.com", Help: "Wasabi AP Northeast 2 (Osaka) endpoint", Provider: "Wasabi", + }, { + Value: "s3.ir-thr-at1.arvanstorage.com", + Help: "ArvanCloud Tehran Iran (Asiatech) endpoint", + Provider: "ArvanCloud", }}, }, { Name: "location_constraint", @@ -1074,6 +1093,17 @@ func init() { Value: "anhui1", Help: "Anhui China (Huainan)", }}, + }, { + Name: "location_constraint", + Help: "Location constraint - must match endpoint.\n\nUsed when creating buckets only.", + Provider: "ArvanCloud", + Examples: []fs.OptionExample{{ + Value: "ir-thr-at1", + Help: "Tehran Iran (Asiatech)", + }, { + Value: "ir-tbz-sh1", + Help: "Tabriz Iran (Shahriar)", + }}, }, { Name: "location_constraint", Help: "Location constraint - must match endpoint when using IBM Cloud Public.\n\nFor on-prem COS, do not make a selection from this list, hit enter.", @@ -1240,7 +1270,7 @@ func init() { }, { Name: "location_constraint", Help: "Location constraint - must be set to match the Region.\n\nLeave blank if not sure. Used when creating buckets only.", - Provider: "!AWS,IBMCOS,Alibaba,ChinaMobile,RackCorp,Scaleway,StackPath,Storj,TencentCOS", + Provider: "!AWS,IBMCOS,Alibaba,ChinaMobile,ArvanCloud,RackCorp,Scaleway,StackPath,Storj,TencentCOS", }, { Name: "acl", Help: `Canned ACL used when creating buckets and storing or copying objects. @@ -1328,7 +1358,7 @@ isn't set then "acl" is used instead.`, }, { Name: "server_side_encryption", Help: "The server-side encryption algorithm used when storing this object in S3.", - Provider: "AWS,Ceph,ChinaMobile,Minio", + Provider: "AWS,Ceph,ChinaMobile,ArvanCloud,Minio", Examples: []fs.OptionExample{{ Value: "", Help: "None", @@ -1343,7 +1373,7 @@ isn't set then "acl" is used instead.`, }, { Name: "sse_customer_algorithm", Help: "If using SSE-C, the server-side encryption algorithm used when storing this object in S3.", - Provider: "AWS,Ceph,ChinaMobile,Minio", + Provider: "AWS,Ceph,ChinaMobile,ArvanCloud,Minio", Advanced: true, Examples: []fs.OptionExample{{ Value: "", @@ -1355,7 +1385,7 @@ isn't set then "acl" is used instead.`, }, { Name: "sse_kms_key_id", Help: "If using KMS ID you must provide the ARN of Key.", - Provider: "AWS,Ceph,Minio", + Provider: "AWS,Ceph,ArvanCloud,Minio", Examples: []fs.OptionExample{{ Value: "", Help: "None", @@ -1366,7 +1396,7 @@ isn't set then "acl" is used instead.`, }, { Name: "sse_customer_key", Help: "If using SSE-C you must provide the secret encryption key used to encrypt/decrypt your data.", - Provider: "AWS,Ceph,ChinaMobile,Minio", + Provider: "AWS,Ceph,ChinaMobile,ArvanCloud,Minio", Advanced: true, Examples: []fs.OptionExample{{ Value: "", @@ -1378,7 +1408,7 @@ isn't set then "acl" is used instead.`, If you leave it blank, this is calculated automatically from the sse_customer_key provided. `, - Provider: "AWS,Ceph,ChinaMobile,Minio", + Provider: "AWS,Ceph,ChinaMobile,ArvanCloud,Minio", Advanced: true, Examples: []fs.OptionExample{{ Value: "", @@ -1452,6 +1482,18 @@ If you leave it blank, this is calculated automatically from the sse_customer_ke Value: "STANDARD_IA", Help: "Infrequent access storage mode", }}, + }, { + // Mapping from here: https://www.arvancloud.com/en/products/cloud-storage + Name: "storage_class", + Help: "The storage class to use when storing new objects in ArvanCloud.", + Provider: "ArvanCloud", + Examples: []fs.OptionExample{{ + Value: "", + Help: "Default", + }, { + Value: "STANDARD", + Help: "Standard storage class", + }}, }, { // Mapping from here: https://intl.cloud.tencent.com/document/product/436/30925 Name: "storage_class", @@ -2167,6 +2209,10 @@ func setQuirks(opt *Options) { listObjectsV2 = false virtualHostStyle = false urlEncodeListings = false + case "ArvanCloud": + listObjectsV2 = false + virtualHostStyle = false + urlEncodeListings = false case "DigitalOcean": urlEncodeListings = false case "Dreamhost": diff --git a/docs/content/_index.md b/docs/content/_index.md index 043cc4c00..1f595763d 100644 --- a/docs/content/_index.md +++ b/docs/content/_index.md @@ -113,6 +113,7 @@ WebDAV or S3, that work out of the box.) {{< provider name="Box" home="https://www.box.com/" config="/box/" >}} {{< provider name="Ceph" home="http://ceph.com/" config="/s3/#ceph" >}} {{< provider name="China Mobile Ecloud Elastic Object Storage (EOS)" home="https://ecloud.10086.cn/home/product-introduction/eos/" config="/s3/#china-mobile-ecloud-eos" >}} +{{< provider name="Arvan Cloud Object Storage (AOS)" home="https://www.arvancloud.com/en/products/cloud-storage" config="/s3/#arvan-cloud-object-storage-aos" >}} {{< provider name="Citrix ShareFile" home="http://sharefile.com/" config="/sharefile/" >}} {{< provider name="C14" home="https://www.online.net/en/storage/c14-cold-storage" config="/s3/#scaleway" >}} {{< provider name="DigitalOcean Spaces" home="https://www.digitalocean.com/products/object-storage/" config="/s3/#digitalocean-spaces" >}} diff --git a/docs/content/s3.md b/docs/content/s3.md index 400bb3059..0cc46fe25 100644 --- a/docs/content/s3.md +++ b/docs/content/s3.md @@ -12,6 +12,7 @@ The S3 backend can be used with a number of different providers: {{< provider name="Alibaba Cloud (Aliyun) Object Storage System (OSS)" home="https://www.alibabacloud.com/product/oss/" config="/s3/#alibaba-oss" >}} {{< provider name="Ceph" home="http://ceph.com/" config="/s3/#ceph" >}} {{< provider name="China Mobile Ecloud Elastic Object Storage (EOS)" home="https://ecloud.10086.cn/home/product-introduction/eos/" config="/s3/#china-mobile-ecloud-eos" >}} +{{< provider name="Arvan Cloud Object Storage (AOS)" home="https://www.arvancloud.com/en/products/cloud-storage" config="/s3/#arvan-cloud-object-storage-aos" >}} {{< provider name="DigitalOcean Spaces" home="https://www.digitalocean.com/products/object-storage/" config="/s3/#digitalocean-spaces" >}} {{< provider name="Dreamhost" home="https://www.dreamhost.com/cloud/storage/" config="/s3/#dreamhost" >}} {{< provider name="IBM COS S3" home="http://www.ibm.com/cloud/object-storage" config="/s3/#ibm-cos-s3" >}} @@ -70,7 +71,7 @@ name> remote Type of storage to configure. Choose a number from below, or type in your own value [snip] -XX / Amazon S3 Compliant Storage Providers including AWS, Ceph, ChinaMobile, Dreamhost, IBM COS, Minio, and Tencent COS +XX / Amazon S3 Compliant Storage Providers including AWS, Ceph, ChinaMobile, ArvanCloud, Dreamhost, IBM COS, Minio, and Tencent COS \ "s3" [snip] Storage> s3 @@ -567,7 +568,7 @@ A simple solution is to set the `--s3-upload-cutoff 0` and force all the files t {{< rem autogenerated options start" - DO NOT EDIT - instead edit fs.RegInfo in backend/s3/s3.go then run make backenddocs" >}} ### Standard options -Here are the standard options specific to s3 (Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, Digital Ocean, Dreamhost, IBM COS, Lyve Cloud, Minio, RackCorp, SeaweedFS, and Tencent COS). +Here are the standard options specific to s3 (Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, ArvanCloud, Digital Ocean, Dreamhost, IBM COS, Lyve Cloud, Minio, RackCorp, SeaweedFS, and Tencent COS). #### --s3-provider @@ -588,6 +589,8 @@ Properties: - Ceph Object Storage - "ChinaMobile" - China Mobile Ecloud Elastic Object Storage (EOS) + - "ArvanCloud" + - Arvan Cloud Object Storage (AOS) - "DigitalOcean" - Digital Ocean Spaces - "Dreamhost" @@ -829,7 +832,7 @@ Properties: - Config: region - Env Var: RCLONE_S3_REGION -- Provider: !AWS,Alibaba,ChinaMobile,RackCorp,Scaleway,Storj,TencentCOS +- Provider: !AWS,Alibaba,ChinaMobile,ArvanCloud,RackCorp,Scaleway,Storj,TencentCOS - Type: string - Required: false - Examples: @@ -926,6 +929,24 @@ Endpoint for China Mobile Ecloud Elastic Object Storage (EOS) API. - "eos-anhui-1.cmecloud.cn" - Anhui China (Huainan) +#### --s3-endpoint + +Endpoint for Arvan Cloud Object Storage (AOS) API. + +- Config: endpoint +- Env Var: RCLONE_S3_ENDPOINT +- Provider: ArvanCloud +- Type: string +- Required: false +- Examples: + - "s3.ir-thr-at1.arvanstorage.com" + - The default endpoint - a good choice if you are unsure. + - Tehran Iran (Asiatech) + - "s3.ir-tbz-sh1.arvanstorage.com" + - Tabriz Iran (Shahriar) + + + #### --s3-endpoint Endpoint for IBM COS S3 API. @@ -1295,7 +1316,7 @@ Properties: - Config: endpoint - Env Var: RCLONE_S3_ENDPOINT -- Provider: !AWS,IBMCOS,TencentCOS,Alibaba,ChinaMobile,Scaleway,StackPath,Storj,RackCorp +- Provider: !AWS,IBMCOS,TencentCOS,Alibaba,ChinaMobile,ArvanCloud,Scaleway,StackPath,Storj,RackCorp - Type: string - Required: false - Examples: @@ -1325,6 +1346,8 @@ Properties: - Wasabi AP Northeast 1 (Tokyo) endpoint - "s3.ap-northeast-2.wasabisys.com" - Wasabi AP Northeast 2 (Osaka) endpoint + - "s3.ir-thr-at1.arvanstorage.com" + - ArvanCloud Tehran Iran (Asiatech) endpoint #### --s3-location-constraint @@ -1532,7 +1555,7 @@ Properties: - Config: location_constraint - Env Var: RCLONE_S3_LOCATION_CONSTRAINT -- Provider: !AWS,IBMCOS,Alibaba,ChinaMobile,RackCorp,Scaleway,StackPath,Storj,TencentCOS +- Provider: !AWS,IBMCOS,Alibaba,ChinaMobile,ArvanCloud,RackCorp,Scaleway,StackPath,Storj,TencentCOS - Type: string - Required: false @@ -1604,7 +1627,7 @@ Properties: - Config: server_side_encryption - Env Var: RCLONE_S3_SERVER_SIDE_ENCRYPTION -- Provider: AWS,Ceph,ChinaMobile,Minio +- Provider: AWS,Ceph,ChinaMobile,ArvanCloud,Minio - Type: string - Required: false - Examples: @@ -1705,6 +1728,21 @@ The storage class to use when storing new objects in ChinaMobile. #### --s3-storage-class +The storage class to use when storing new objects in ChinaMobile. + +- Config: storage_class +- Env Var: RCLONE_S3_STORAGE_CLASS +- Provider: ArvanCloud +- Type: string +- Required: false +- Examples: + - "" + - Default + - "STANDARD" + - Standard storage class + +#### --s3-storage-class + The storage class to use when storing new objects in Tencent COS. Properties: @@ -1747,7 +1785,7 @@ Properties: ### Advanced options -Here are the advanced options specific to s3 (Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, Digital Ocean, Dreamhost, IBM COS, Lyve Cloud, Minio, RackCorp, SeaweedFS, and Tencent COS). +Here are the advanced options specific to s3 (Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, ArvanCloud, Digital Ocean, Dreamhost, IBM COS, Lyve Cloud, Minio, RackCorp, SeaweedFS, and Tencent COS). #### --s3-bucket-acl @@ -1799,7 +1837,7 @@ Properties: - Config: sse_customer_algorithm - Env Var: RCLONE_S3_SSE_CUSTOMER_ALGORITHM -- Provider: AWS,Ceph,ChinaMobile,Minio +- Provider: AWS,Ceph,ChinaMobile,ArvanCloud,Minio - Type: string - Required: false - Examples: @@ -1816,7 +1854,7 @@ Properties: - Config: sse_customer_key - Env Var: RCLONE_S3_SSE_CUSTOMER_KEY -- Provider: AWS,Ceph,ChinaMobile,Minio +- Provider: AWS,Ceph,ChinaMobile,ArvanCloud,Minio - Type: string - Required: false - Examples: @@ -1834,7 +1872,7 @@ Properties: - Config: sse_customer_key_md5 - Env Var: RCLONE_S3_SSE_CUSTOMER_KEY_MD5 -- Provider: AWS,Ceph,ChinaMobile,Minio +- Provider: AWS,Ceph,ChinaMobile,ArvanCloud,Minio - Type: string - Required: false - Examples: @@ -2615,7 +2653,7 @@ Choose a number from below, or type in your own value \ "alias" 2 / Amazon Drive \ "amazon cloud drive" - 3 / Amazon S3 Complaint Storage Providers (Dreamhost, Ceph, ChinaMobile, Minio, IBM COS) + 3 / Amazon S3 Complaint Storage Providers (Dreamhost, Ceph, ChinaMobile, ArvanCloud, Minio, IBM COS) \ "s3" 4 / Backblaze B2 \ "b2" @@ -2900,7 +2938,7 @@ Choose `s3` backend Type of storage to configure. Choose a number from below, or type in your own value. [snip] -XX / Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, Digital Ocean, Dreamhost, IBM COS, Lyve Cloud, Minio, RackCorp, SeaweedFS, and Tencent COS +XX / Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, ArvanCloud, Digital Ocean, Dreamhost, IBM COS, Lyve Cloud, Minio, RackCorp, SeaweedFS, and Tencent COS \ (s3) [snip] Storage> s3 @@ -3087,7 +3125,7 @@ name> wasabi Type of storage to configure. Choose a number from below, or type in your own value [snip] -XX / Amazon S3 (also Dreamhost, Ceph, ChinaMobile, Minio) +XX / Amazon S3 (also Dreamhost, Ceph, ChinaMobile, ArvanCloud, Minio) \ "s3" [snip] Storage> s3 @@ -3201,7 +3239,7 @@ Type of storage to configure. Enter a string value. Press Enter for the default (""). Choose a number from below, or type in your own value [snip] - 4 / Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, Digital Ocean, Dreamhost, IBM COS, Minio, and Tencent COS + 4 / Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, ArvanCloud, Digital Ocean, Dreamhost, IBM COS, Minio, and Tencent COS \ "s3" [snip] Storage> s3 @@ -3541,6 +3579,114 @@ d) Delete this remote y/e/d> y ``` +### ArvanCloud + +[ArvanCloud](https://www.arvancloud.com/en/products/cloud-storage) ArvanCloud Object Storage goes beyond the limited traditional file storage. +It gives you access to backup and archived files and allows sharing. +Files like profile image in the app, images sent by users or scanned documents can be stored securely and easily in our Object Storage service. + +ArvanCloud provides an S3 interface which can be configured for use with +rclone like this. + +``` +No remotes found, make a new one? +n) New remote +s) Set configuration password +n/s> n +name> ArvanCloud +Type of storage to configure. +Choose a number from below, or type in your own value +[snip] +XX / Amazon S3 (also Dreamhost, Ceph, ChinaMobile, ArvanCloud, Minio) + \ "s3" +[snip] +Storage> s3 +Get AWS credentials from runtime (environment variables or EC2/ECS meta data if no env vars). Only applies if access_key_id and secret_access_key is blank. +Choose a number from below, or type in your own value + 1 / Enter AWS credentials in the next step + \ "false" + 2 / Get AWS credentials from the environment (env vars or IAM) + \ "true" +env_auth> 1 +AWS Access Key ID - leave blank for anonymous access or runtime credentials. +access_key_id> YOURACCESSKEY +AWS Secret Access Key (password) - leave blank for anonymous access or runtime credentials. +secret_access_key> YOURSECRETACCESSKEY +Region to connect to. +Choose a number from below, or type in your own value + / The default endpoint - a good choice if you are unsure. + 1 | US Region, Northern Virginia, or Pacific Northwest. + | Leave location constraint empty. + \ "us-east-1" +[snip] +region> +Endpoint for S3 API. +Leave blank if using ArvanCloud to use the default endpoint for the region. +Specify if using an S3 clone such as Ceph. +endpoint> s3.arvanstorage.com +Location constraint - must be set to match the Region. Used when creating buckets only. +Choose a number from below, or type in your own value + 1 / Empty for Iran-Tehran Region. + \ "" +[snip] +location_constraint> +Canned ACL used when creating buckets and/or storing objects in S3. +For more info visit https://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#canned-acl +Choose a number from below, or type in your own value + 1 / Owner gets FULL_CONTROL. No one else has access rights (default). + \ "private" +[snip] +acl> +The server-side encryption algorithm used when storing this object in S3. +Choose a number from below, or type in your own value + 1 / None + \ "" + 2 / AES256 + \ "AES256" +server_side_encryption> +The storage class to use when storing objects in S3. +Choose a number from below, or type in your own value + 1 / Default + \ "" + 2 / Standard storage class + \ "STANDARD" +storage_class> +Remote config +-------------------- +[ArvanCloud] +env_auth = false +access_key_id = YOURACCESSKEY +secret_access_key = YOURSECRETACCESSKEY +region = ir-thr-at1 +endpoint = s3.arvanstorage.com +location_constraint = +acl = +server_side_encryption = +storage_class = +-------------------- +y) Yes this is OK +e) Edit this remote +d) Delete this remote +y/e/d> y +``` + +This will leave the config file looking like this. + +``` +[ArvanCloud] +type = s3 +provider = ArvanCloud +env_auth = false +access_key_id = YOURACCESSKEY +secret_access_key = YOURSECRETACCESSKEY +region = +endpoint = s3.arvanstorage.com +location_constraint = +acl = +server_side_encryption = +storage_class = +``` + ### Tencent COS {#tencent-cos} [Tencent Cloud Object Storage (COS)](https://intl.cloud.tencent.com/product/cos) is a distributed storage service offered by Tencent Cloud for unstructured data. It is secure, stable, massive, convenient, low-delay and low-cost. @@ -3574,7 +3720,7 @@ Choose a number from below, or type in your own value \ "alias" 3 / Amazon Drive \ "amazon cloud drive" - 4 / Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, Digital Ocean, Dreamhost, IBM COS, Minio, and Tencent COS + 4 / Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, ChinaMobile, ArvanCloud, Digital Ocean, Dreamhost, IBM COS, Minio, and Tencent COS \ "s3" [snip] Storage> s3