how to reference volume in code.
I have code that writes when POST an excel file in the project directory for future referencing... i know databases exists but that's how the client wanted it lol the issue is of course since the service the files are ephiemeral on a redeploy they disappeared i attached a volume but tbh i have no idea on how to write to it
like i'm actually using
const excelDirPath = join(process.cwd(), 'excel');
const excelFilePath = join(excelDirPath, 'calc.xlsx');
and i mounted /excel in the volume does that automagically works or i have to adjust it?
Solution:Jump to solution
if you mount a volume to
/excel
you write into /excel
no need to overthink it...8 Replies
Project ID:
N/A
N/A
Solution
if you mount a volume to
/excel
you write into /excel
no need to overthink itjoin(process.cwd(), 'excel');
this results in something like /app/excel
aka the wrong directoryok daddy thank you
bruh
:sus_apple:
🤨