File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -144,6 +144,16 @@ The client specified MUST implement functions called `getObject` and `putObject`
144
144
145
145
* Default:* the default S3 library is ` aws-sdk `
146
146
147
+ ### endpoint
148
+
149
+ AWS (or AWS compatible endpoint) to use. E.g. with DigitalOcean Spaces, Microsoft Azure Blob Storage,
150
+ or Openstack Swift
151
+
152
+ If ` endpoint ` set the ` region ` option will be ignored.
153
+
154
+ * Default:* ` [region].s3.amazonaws.com `
155
+
156
+
147
157
### serverSideEncryption
148
158
149
159
The Server-side encryption algorithm used when storing this object in S3 (e.g., AES256, aws: kms ). Possible values include:
Original file line number Diff line number Diff line change @@ -30,6 +30,7 @@ module.exports = CoreObject.extend({
30
30
var plugin = options . plugin ;
31
31
var config = plugin . pluginConfig ;
32
32
var profile = plugin . readConfig ( 'profile' ) ;
33
+ var endpoint = plugin . readConfig ( 'endpoint' ) ;
33
34
34
35
this . _plugin = plugin ;
35
36
@@ -38,6 +39,11 @@ module.exports = CoreObject.extend({
38
39
AWS . config . credentials = new AWS . SharedIniFileCredentials ( { profile : profile } ) ;
39
40
}
40
41
42
+ if ( endpoint ) {
43
+ this . plugin . log ( 'Using endpoint from config' , { verbose : true } ) ;
44
+ AWS . config . endpoint = new AWS . Endpoint ( endpoint ) ;
45
+ }
46
+
41
47
this . _client = plugin . readConfig ( 's3Client' ) || new AWS . S3 ( config ) ;
42
48
} ,
43
49
You can’t perform that action at this time.
0 commit comments