forked from TrueCloudLab/rclone
Command line argument for setting/overriding Amazon S3 ACL
This commit is contained in:
parent
ace1e21894
commit
bc414b698d
2 changed files with 9 additions and 2 deletions
|
@ -233,7 +233,13 @@ credentials then S3 interaction will be non-authenticated (see below).
|
||||||
Here are the command line options specific to this cloud storage
|
Here are the command line options specific to this cloud storage
|
||||||
system.
|
system.
|
||||||
|
|
||||||
#### ----s3-storage-class ####
|
#### --s3-acl=STRING ####
|
||||||
|
|
||||||
|
Canned ACL used when creating buckets and/or storing objects in S3.
|
||||||
|
|
||||||
|
For more info visit the [canned ACL docs](http://docs.aws.amazon.com/AmazonS3/latest/dev/acl-overview.html#canned-acl).
|
||||||
|
|
||||||
|
#### --s3-storage-class=STRING ####
|
||||||
|
|
||||||
Storage class to upload new objects with.
|
Storage class to upload new objects with.
|
||||||
|
|
||||||
|
|
3
s3/s3.go
3
s3/s3.go
|
@ -210,6 +210,7 @@ const (
|
||||||
// Globals
|
// Globals
|
||||||
var (
|
var (
|
||||||
// Flags
|
// Flags
|
||||||
|
s3ACL = pflag.StringP("s3-acl", "", "", "Canned ACL used when creating buckets and/or storing objects in S3")
|
||||||
s3StorageClass = pflag.StringP("s3-storage-class", "", "", "Storage class to use when uploading S3 objects (STANDARD|REDUCED_REDUNDANCY|STANDARD_IA)")
|
s3StorageClass = pflag.StringP("s3-storage-class", "", "", "Storage class to use when uploading S3 objects (STANDARD|REDUCED_REDUNDANCY|STANDARD_IA)")
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -367,7 +368,7 @@ func NewFs(name, root string) (fs.Fs, error) {
|
||||||
c: c,
|
c: c,
|
||||||
bucket: bucket,
|
bucket: bucket,
|
||||||
ses: ses,
|
ses: ses,
|
||||||
acl: fs.ConfigFile.MustValue(name, "acl"),
|
acl: fs.ConfigFile.MustValue(name, "acl", *s3ACL),
|
||||||
root: directory,
|
root: directory,
|
||||||
locationConstraint: fs.ConfigFile.MustValue(name, "location_constraint"),
|
locationConstraint: fs.ConfigFile.MustValue(name, "location_constraint"),
|
||||||
sse: fs.ConfigFile.MustValue(name, "server_side_encryption"),
|
sse: fs.ConfigFile.MustValue(name, "server_side_encryption"),
|
||||||
|
|
Loading…
Add table
Reference in a new issue