Skip to content
This repository was archived by the owner on Feb 11, 2018. It is now read-only.

Commit 3c069ed

Browse files
committed
update s3 token (optional)
1 parent 72243e6 commit 3c069ed

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

config/config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ config.development = {
2121
s3: {
2222
accessKeyId: process.env.AWS_ACCESS_KEY_ID,
2323
secretAccessKey: process.env.AWS_SECRET_ACCESS_KEY,
24+
sessionToken: process.env.AWS_SESSION_TOKEN, //(optional)
2425
bucketName: process.env.BUCKET_NAME,
2526
region: process.env.REGION,
2627
downloadUrl: process.env.DOWNLOAD_URL, // binary files download host address.

core/utils/common.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -231,6 +231,7 @@ common.uploadFileToS3 = function (key, filePath) {
231231
AWS.config.update({
232232
accessKeyId: _.get(config, 's3.accessKeyId'),
233233
secretAccessKey: _.get(config, 's3.secretAccessKey'),
234+
sessionToken: _.get(config, 's3.sessionToken'),
234235
region: _.get(config, 's3.region')
235236
});
236237
var s3 = new AWS.S3({

0 commit comments

Comments
 (0)