Set ACL when uploading objects
This commit is contained in:
parent
1f6125be8b
commit
0d4a3c62ab
|
@ -146,7 +146,8 @@ async function objectStoragePut (options: {
|
||||||
const command = new PutObjectCommand({
|
const command = new PutObjectCommand({
|
||||||
Bucket: bucketInfo.BUCKET_NAME,
|
Bucket: bucketInfo.BUCKET_NAME,
|
||||||
Key: buildKey(objectStorageKey, bucketInfo),
|
Key: buildKey(objectStorageKey, bucketInfo),
|
||||||
Body: content
|
Body: content,
|
||||||
|
ACL: 'public-read'
|
||||||
})
|
})
|
||||||
|
|
||||||
await getClient().send(command)
|
await getClient().send(command)
|
||||||
|
@ -168,7 +169,8 @@ async function multiPartUpload (options: {
|
||||||
|
|
||||||
const createMultipartCommand = new CreateMultipartUploadCommand({
|
const createMultipartCommand = new CreateMultipartUploadCommand({
|
||||||
Bucket: bucketInfo.BUCKET_NAME,
|
Bucket: bucketInfo.BUCKET_NAME,
|
||||||
Key: key
|
Key: key,
|
||||||
|
ACL: 'public-read'
|
||||||
})
|
})
|
||||||
const createResponse = await s3Client.send(createMultipartCommand)
|
const createResponse = await s3Client.send(createMultipartCommand)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue