`ReferenceError: require is not defined` when added bookshelf.js

Only adding the file bookshelf.js:

var knex = require('knex')({
  client: 'mysql',
  connection: {
    host     : 'localhost',
    user     : 'root',
    password : 'root',
    database : 'switchboard',
    charset  : 'utf8'

module.exports = require('bookshelf')(knex);

giving the error:

=> Exited with code: 8
W20151027-17:47:44.358(9)? (STDERR)
W20151027-17:47:44.358(9)? (STDERR) /Users/askar/.meteor/packages/meteor-tool/.
W20151027-17:47:44.358(9)? (STDERR) 						throw(ex);
W20151027-17:47:44.358(9)? (STDERR) 						      ^
W20151027-17:47:44.359(9)? (STDERR) ReferenceError: require is not defined

Repot https://github.com/tenzan/sb2-mongo-mysql/tree/bookshelf

I assume ReferenceError: require is not defined is referring to the 1st line require('knex'), but it gives me now idea what it is.