Notwithstanding Previous Misdemeanors
    Wondering what’s next for npm?Check out our public roadmap! »

    haibu-api

    0.9.0 • Public • Published

    haibu-api (node.js)

    The node.js client for the haibu API.

    Usage

    Allows you to call haibu programmatically from inside your node.js scripts.

    var eyes = require('eyes'),
        haibu = require('haibu');
     
    // Create a new client for communicating with the haibu server
    var client = new haibu.drone.Client({
      host: 'localhost',
      port: 9002
    });
     
    // A basic package.json for a node.js application on haibu
    var app = {
      "user": "marak",
      "name": "test",
      "domain": "devjitsu.com",
      "repository": {
        "type": "git",
        "url": "https://github.com/Marak/hellonode.git",
      },
      "scripts": {
        "start": "server.js"
      }
    };
     
    // Attempt to start up a new application
    client.start(app, function (err, result) {
      if (err) {
        console.log('Error spawning app: ' + app.name);
        return eyes.inspect(err);
      }
     
      console.log('Successfully spawned app:');
      eyes.inspect(result);
    });
     
     
    client.start(app, function (err, result) {
      eyes.inspect(err);
      eyes.inspect(result);
    });

    Run Tests

    All of the haibu tests are written in [vows][0], and cover all of the use cases described above.

      $ npm test

    License: MIT

    Author: Nodejitsu Inc

    Contributors: Maciej Malecki, Charlie Robbins

    Keywords

    none

    Install

    npm i haibu-api

    DownloadsWeekly Downloads

    2

    Version

    0.9.0

    License

    none

    Last publish

    Collaborators

    • avatar