public async create({ request, response }: HttpContextContract) {
try {
await request.multipart
.onFile(
'file',
{
size: '900mb',
},
async (file, reportChunk) => {
await Drive.putStream(`teste/${file.filename}`, file.file, {
contentType: file.file.type,
visibility: 'private',
})
}
)
.process()
return response.ok(request.multipart.state)
} catch (error) {
console.log(error)
}
}
Route receives multipart file and it does not work. Tryna do this https://docs.adonisjs.com/guides/direct-file-uploads with s3 driver but not working.