Option objectStorageSetPublicRead (#6645)

This commit is contained in:
MeiMei 2020-08-13 20:05:01 +09:00 committed by GitHub
parent bb342c7601
commit ee0a445590
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 34 additions and 0 deletions

View file

@ -212,6 +212,7 @@ async function upload(key: string, stream: fs.ReadStream | Buffer, type: string,
} as S3.PutObjectRequest;
if (filename) params.ContentDisposition = contentDisposition('inline', filename);
if (meta.objectStorageSetPublicRead) params.ACL = 'public-read';
const s3 = getS3(meta);