Hi there
I am building a Meteor application to split uploaded audio files
I upload the audio files and store them using GridFS
child = Npm.require(‘child_process’);
var fs = Npm.require('fs');
storagePath= fs.realpathSync(process.env.PWD+'/audio');
StaticServer.add('/audio', clipsPath);
and then using a method i split the audio file using
child.exec(command);
the command is the ffmpeg command used to cut the source audio file and store it on the storagePath
the application worked fine locally but when I tried to deploy it to digital ocian i got errors , stating that the file /audio doesnot exist
I use mupx to deploy and the error appears after “verifying deployment”
here is the error
-----------------------------------STDERR-----------------------------------
eteor-dev-bundle@0.0.0 No README data
=> Starting meteor app on port:80
/bundle/bundle/programs/server/node_modules/fibers/future.js:245
throw(ex);
^
Error: ENOENT, no such file or directory '/bundle/bundle/audio'
at Object.fs.lstatSync (fs.js:691:18)
at Object.realpathSync (fs.js:1279:21)
at server/startup.js:10:20
at /bundle/bundle/programs/server/boot.js:249:5
npm WARN package.json meteor-dev-bundle@0.0.0 No description
npm WARN package.json meteor-dev-bundle@0.0.0 No repository field.
npm WARN package.json meteor-dev-bundle@0.0.0 No README data
=> Starting meteor app on port:80
/bundle/bundle/programs/server/node_modules/fibers/future.js:245
throw(ex);
^
Error: ENOENT, no such file or directory '/bundle/bundle/audio'
at Object.fs.lstatSync (fs.js:691:18)
at Object.realpathSync (fs.js:1279:21)
at server/startup.js:10:20
at /bundle/bundle/programs/server/boot.js:249:5
=> Redeploying previous version of the app
-----------------------------------STDOUT-----------------------------------
To see more logs type 'mup logs --tail=50'
----------------------------------------------------------------------------
the main quistion is , how to i generate an output file using ffmpeg command and store it in a place where I can access it and display it on the browser?
should I use CollectionFS ?
if so , how , this problem is killing me