fix minio

This commit is contained in:
Arthur Barre 2025-03-16 19:40:45 +01:00
parent 8b6d76fdea
commit fe493fe053

View File

@ -3,9 +3,13 @@ const Minio = require('minio');
const minioClient = new Minio.Client({ const minioClient = new Minio.Client({
endPoint: process.env.MINIO_ENDPOINT.replace(/^https?:\/\//, ''), endPoint: process.env.MINIO_ENDPOINT.replace(/^https?:\/\//, ''),
port: parseInt(process.env.MINIO_PORT), port: parseInt(process.env.MINIO_PORT),
useSSL: process.env.MINIO_USE_SSL === 'true', useSSL: false,
accessKey: process.env.MINIO_ACCESS_KEY, accessKey: process.env.MINIO_ACCESS_KEY,
secretKey: process.env.MINIO_SECRET_KEY, secretKey: process.env.MINIO_SECRET_KEY,
pathStyle: true,
transport: {
agent: false,
}
}); });
const uploadFile = async (file, folderPath) => { const uploadFile = async (file, folderPath) => {