added mozlog and file exists route
This commit is contained in:
parent
f9c2eb1ae4
commit
900fe32460
9 changed files with 127 additions and 49 deletions
15
server/log.js
Normal file
15
server/log.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
const conf = require('./config.js');
|
||||
|
||||
let notLocalHost =
|
||||
conf.env === 'production' &&
|
||||
conf.s3_bucket !== 'localhost' &&
|
||||
conf.bitly_key !== 'localhost';
|
||||
|
||||
const mozlog = require('mozlog') ({
|
||||
app: 'FirefoxFileshare',
|
||||
level: notLocalHost ? 'INFO' : 'verbose',
|
||||
fmt: notLocalHost ? 'heka' : 'pretty',
|
||||
debug: !notLocalHost
|
||||
})
|
||||
|
||||
module.exports = mozlog;
|
Loading…
Add table
Add a link
Reference in a new issue