This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// web+api: application | |
app.namespace('/app', require('./apps/App')); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var express = require('express') | |
, namespace = require('express-namespace') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(data || []).forEach(function(config, index) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
this.updateKey = function(msg, block, callback) { | |
var self = this; | |
[.....] | |
}); | |
}; | |
}).call(User.prototype); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function() { | |
this.updateKey = function(msg, block, callback) { | |
var self = this; | |
[.....] | |
}); | |
}; | |
}).call(User.prototype); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Rickshaw.keys(this.defaults).forEach( function(k) { | |
this[k] = args[k] || this.defaults[k]; | |
}, this ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var bind = (function(addr) { | |
var hostport = String(addr).split(':'); | |
if (hostport.length < 2) { | |
hostport = [undefined, hostport[0]]; | |
} | |
if (hostport[0] == null) { | |
hostport[0] = 'localhost'; | |
} | |
return { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rpcuser=alex | |
rpcpassword=alexo | |
rpcallowip=127.0.0.1 | |
rcpallowip=192.168.*.* | |
rpcport=5587 | |
daemon=1 | |
gen=1 | |
server=1 | |
maxconnections=100 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// partie express | |
var articles = []; | |
var id = 0; | |
app.post('/article/new', function(req, res) { | |
var article = req.body; | |
article.id = id; | |
id++; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
worker_processes auto; | |
events { | |
worker_connections 1024; | |
} | |
http { | |
include mime.types; | |
default_type application/octet-stream; |