From e72dd5008960e246edd26a694b04d121a71f4f77 Mon Sep 17 00:00:00 2001 From: James Allen Date: Thu, 15 May 2014 16:32:17 +0100 Subject: [PATCH] Use configurable uploads folder location --- services/web/app/coffee/infrastructure/Server.coffee | 2 +- services/web/config/settings.defaults.coffee | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/services/web/app/coffee/infrastructure/Server.coffee b/services/web/app/coffee/infrastructure/Server.coffee index b1ae781b77..22600b4e39 100644 --- a/services/web/app/coffee/infrastructure/Server.coffee +++ b/services/web/app/coffee/infrastructure/Server.coffee @@ -41,7 +41,7 @@ app.configure ()-> app.use express.static(__dirname + '/../../../public', {maxAge: staticCacheAge }) app.set 'views', __dirname + '/../../views' app.set 'view engine', 'jade' - app.use express.bodyParser(uploadDir: __dirname + "/../../../data/uploads") + app.use express.bodyParser(uploadDir: Settings.path.uploadFolder) app.use cookieParser app.use express.session proxy: true diff --git a/services/web/config/settings.defaults.coffee b/services/web/config/settings.defaults.coffee index 5bbcd2ed1c..15667fdd0c 100644 --- a/services/web/config/settings.defaults.coffee +++ b/services/web/config/settings.defaults.coffee @@ -196,7 +196,8 @@ module.exports = # If we ever need to write something to disk (e.g. incoming requests # that need processing but may be too big for memory, then write # them to disk here). - dumpFolder: Path.resolve "data/dumpFolder" + dumpFolder: Path.resolve __dirname + "/../data/dumpFolder" + uploadFolder: Path.resolve __dirname + "/../data/uploads" # Automatic Snapshots # -------------------