I am initializing the bunyan logger in my nodejs code as below:
var log = bunyan.createLogger({ name: \'myapp\', stream: process.stdout, level: \
process.stdout is for Logging on Console.
If you want to log on a file you need to provide different streams.
var log = bunyan.createLogger({ name: 'myapp', streams: [ { level: 'trace', stream: process.stdout }, { level: 'warn', path: './filename.log' } ] });