Skip to content

Commit

Permalink
Set ACL when uploading objects
Browse files Browse the repository at this point in the history
  • Loading branch information
Chocobozzz committed Aug 18, 2021
1 parent 1f6125b commit 0d4a3c6
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions server/lib/object-storage/shared/object-storage-helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand All @@ -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)

Expand Down

0 comments on commit 0d4a3c6

Please sign in to comment.