How to use the sails.lift function in sails

To help you get started, we’ve selected a few sails examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github benetech / mmlc-api / test / features / support / hooks.js View on Github external
BeforeAll(function(done) {
    // Tests expect to run with NODE_ENV=development
    process.env.NODE_ENV = 'development';
    sails.lift({
        // Your sails app's configuration files will be loaded automatically,
        // but you can also specify any other special overrides here for testing purposes.

        // For example, we might want to skip the Grunt hook,
        // and disable all logs except errors:
        hooks: { grunt: false },
        log: { level: 'info' },
    }, done);
});
github microsoft / devops-project-samples / node / sail.js / kubernetes / Application / app.js View on Github external
rc = require('rc');
} catch (e0) {
  try {
    rc = require('sails/node_modules/rc');
  } catch (e1) {
    console.error('Could not find dependency: `rc`.');
    console.error('Your `.sailsrc` file(s) will be ignored.');
    console.error('To resolve this, run:');
    console.error('npm install rc --save');
    rc = function () { return {}; };
  }
}

appInsights.start();
// Start server
sails.lift(rc('sails'));
github Yomguithereal / mtgnode / app.js View on Github external
// Start sails and pass it command line arguments
require('sails').lift(require('optimist').argv);
github 1PhoenixM / avior-service / old_sails_demo / app.js View on Github external
// Start sails and pass it command line arguments
require('sails').lift(require('optimist').argv);
github stefanbuck / sails-social-auth-example / app.js View on Github external
// Start sails and pass it command line arguments
require('sails').lift(require('optimist').argv);
github swelham / sails-jwt-example / test / index.js View on Github external
before(function (done) {
  this.timeout(5000);

  var config = {
    log: {
      level: 'error'
    }/*,
    connections: {
      default: 'localDiskDb'
    }*/
  };

  Sails.lift(config, function (err, s) {
    if (err) return done(err);

    console.log('sails lift\n');
    global.sails_app = s.hooks.http.app;

    done();
  });
});
github linxiaowu66 / douMiBlog-Sailsjs / test / setup.js View on Github external
before(function(done) {
  this.timeout(5000);
  Sails.lift({
    port: 8989,
    log: {
      noShip: true
    },
    hooks: {
      grunt: false
    },
    models: {
      connection: 'localDiskDb',
      migrate: 'drop'
    }

  }, done);
});
github zand3rs / sails-test-helper / lib / bootstrap.js View on Github external
beforeAll(function(done) {
  Sails.lift(rc("sails"), function(err, sails) {
    done && done(err, sails);
  });
});
github engineer-man / emkc / platform / engineerman.js View on Github external
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU Affero General Public License for more details.
 *
 * You should have received a copy of the GNU Affero General Public License
 * along with this program.  If not, see .
 *
 * If your software can interact with users remotely through a computer
 * network, you should also make sure that it provides a way for users to
 * get its source.  For example, if your program is a web application, its
 * interface could display a "Source" link that leads users to an archive
 * of the code.  There are many ways you could offer source, and different
 * solutions will be better for different programs; see section 13 for the
 * specific requirements.
**/

require('sails')
    .lift(require('optimist').argv);