Set ACL when uploading objects

pull/4337/head
Chocobozzz 2021-08-18 09:19:09 +02:00
parent 1f6125be8b
commit 0d4a3c62ab
No known key found for this signature in database
GPG Key ID: 583A612D890159BE
1 changed files with 4 additions and 2 deletions

View File

@ -146,7 +146,8 @@ async function objectStoragePut (options: {
const command = new PutObjectCommand({
Bucket: bucketInfo.BUCKET_NAME,
Key: buildKey(objectStorageKey, bucketInfo),
Body: content
Body: content,
ACL: 'public-read'
})
await getClient().send(command)
@ -168,7 +169,8 @@ async function multiPartUpload (options: {
const createMultipartCommand = new CreateMultipartUploadCommand({
Bucket: bucketInfo.BUCKET_NAME,
Key: key
Key: key,
ACL: 'public-read'
})
const createResponse = await s3Client.send(createMultipartCommand)