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
| # Mongodb upstart file at /etc/init/mongodb.conf | |
| description "Runs mongod server daemon as service." | |
| start on runlevel [2345] | |
| stop on runlevel [06] | |
| respawn | |
| respawn limit 10 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
| # Mongodb upstart file at /etc/init/mongodb.conf | |
| description "Runs mongod server daemon as service." | |
| start on runlevel [2345] | |
| stop on runlevel [06] | |
| respawn | |
| respawn limit 10 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
| @version: 3.0 | |
| source s_system { | |
| internal(); | |
| unix-stream("/dev/log"); | |
| file("/proc/kmsg" program_override("kernel: ")); | |
| file("/var/log/daemon.log" follow_freq(1) flags(no-parse)); | |
| file("/var/log/dpkg.log" follow_freq(1) flags(no-parse)); | |
| }; | |
| source s_mongo { |
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 should = require('should'), | |
| srcd = process.cwd() + '/src', | |
| rd = srcd + '/routines', | |
| runner = require(rd + '/server/runner'), | |
| configurer = require(rd + '/server/configurer'), | |
| creator = require(rd + '/server/creator'), | |
| EventEmitter2 = require('eventemitter2').EventEmitter2, | |
| config = require(srcd + '/config'), | |
| express = require('express'); |
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 cluster = require('cluster'), | |
| nrCPUs = require('os').cpus().length; | |
| //when we are the master | |
| if (cluster.isMaster) { | |
| //fork workers (one for each CPU) | |
| for (var i = 0; i < nrCPUs; i++) { | |
| spawnWorker(); | |
| } |
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
| app.get('*', function(req, res) { | |
| req.once('end', function() { | |
| require('util').debug('!!! THIS NEVER FIRES, req: ' + req.url); | |
| }); | |
| res.writeHead(404); | |
| res.end('My apologies, the request you performed cannot be answered (404). Please check for possbile typing errors.'); |
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
| module.exports = function(mediator) { | |
| var express = require('express'); | |
| mediator.once('boot.ready', function() { | |
| var server = express.createServer(); | |
| //event: server created | |
| process.nextTick(function() { |
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 EventEmitter2 = require('eventemitter2').EventEmitter2, | |
| EEPatcher = require('../../src/util/eepatcher')(EventEmitter2), | |
| util = require('util'), | |
| should = require('should'), | |
| emitter = new EventEmitter2({ | |
| wildcard: false | |
| }); | |
| describe('eepatcher', function() { |
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
| module.exports = function(mediator) { | |
| var mongo = require('mongodb'), | |
| Server = mongo.Server, | |
| Db = mongo.Db, | |
| ReplSet = mongo.ReplSet, | |
| config = require('../../config'), | |
| replSetName = config.mongo.rsname, | |
| servers = config.mongo.servers, | |
| dbName = config.mongo.dbname; |
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
| deploy-git: | |
| status=$$(git status --porcelain) \ | |
| echo $${status} |