mirror of
https://github.com/rustfs/console.git
synced 2026-09-01 15:17:45 +08:00
fix: large file upload
This commit is contained in:
@@ -115,9 +115,7 @@ class UploadTaskManager {
|
||||
const command = new PutObjectCommand({
|
||||
Bucket: bucketName,
|
||||
Key: prefix + task.file.name,
|
||||
// Body: file,
|
||||
// https://github.com/aws/aws-sdk-js-v3/issues/6834
|
||||
Body: new Uint8Array(fileBuffer),
|
||||
Body: file,
|
||||
ContentType: file.type,
|
||||
});
|
||||
|
||||
|
||||
@@ -17,6 +17,8 @@ export default defineNuxtPlugin({
|
||||
const client = new S3Client({
|
||||
endpoint: siteConfig.s3.endpoint,
|
||||
region: siteConfig.s3.region || 'us-east-1',
|
||||
// https://github.com/aws/aws-sdk-js-v3/issues/6834#issuecomment-2611346849
|
||||
requestChecksumCalculation: "WHEN_REQUIRED",
|
||||
credentials: {
|
||||
accessKeyId: credentials.value?.AccessKeyId || '',
|
||||
secretAccessKey: credentials.value?.SecretAccessKey || '',
|
||||
|
||||
Reference in New Issue
Block a user