feat: pass content type

This commit is contained in:
karishmas6
2024-10-16 01:40:20 +05:30
parent 3f4b67b05a
commit 6062b10beb

View File

@@ -47,7 +47,7 @@ class Run extends Model<RunAttributes, RunCreationAttributes> implements RunAttr
try {
console.log(`Uploading to bucket ${bucketName} with key ${key}`);
await minioClient.putObject(bucketName, key, data);
await minioClient.putObject(bucketName, key, data, data.length, { 'Content-Type': 'image/png' });
this.binaryOutput[key] = `minio://${bucketName}/${key}`;
console.log(`Successfully uploaded to MinIO: minio://${bucketName}/${key}`);
} catch (error) {