Skip to content

Instantly share code, notes, and snippets.

Niall O'Higgins niallo

Block or report user

Report or block niallo

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@niallo
niallo / docker.sh
Last active Dec 30, 2015
Customize Strider Docker via environment variables
View docker.sh
docker run -d -p 3000:3000 \
-e SERVER_NAME=https://strider.myhost.com \
-e DB_URI=mongodb://foo.com/strider \
-e PLUGIN_GITHUB_APP_ID=foo \
-e PLUGIN_GITHUB_APP_SECRET=bar niallo/strider
View gist:6768965
5:::{"name":"job.done","args":[{"deploy_exitcode":-1,"test_exitcode":-1,"duration":3351,"finished":"2013-09-30T19:35:11.886Z","started":"2013-09-30T19:35:08.535Z","queued":"2013-09-30T19:35:08.534Z","__v":0,"_id":"5249d26bb8305d3089000017","created":"2013-09-30T19:35:07.451Z","project":{"_id":"5249d032a7fe37038900000a","name":"strider-cd/strider-extension-loader","branches":{"master":{"plugins":[],"active":true,"deploy_on_green":true,"runner":{"id":"simple-runner"}}},"public":true,"display_url":"https://github.com/Strider-CD/strider-extension-loader","provider":{"id":"github"}},"ref":{"branch":"master"},"type":"TEST_ONLY","user_id":"51f050cf04568a0c00000008","runner":{"id":"simple-runner"},"errored":false,"trigger":{"type":"manual","message":"Retest","timestamp":"2013-09-30T19:35:07.451Z","source":{"type":"UI","page":"unknown"},"author":{"id":"51f050cf04568a0c00000008","email":"n@niallo.me","image":null}},"status":"failed"},"public"]}
View gist:6768817
/Users/niallo/projects/strider-14/strider/lib/websockets.js:110
id: user._id,
^
TypeError: Cannot read property '_id' of null
at kickoffJob (/Users/niallo/projects/strider-14/strider/lib/websockets.js:110:15)
at Object.UserSocket.events.test (/Users/niallo/projects/strider-14/strider/lib/websockets.js:180:7)
at Socket.EventEmitter.emit [as $emit] (events.js:95:17)
at SocketNamespace.handlePacket (/Users/niallo/projects/strider-14/strider/node_modules/socket.io/lib/namespace.js:335:22)
at Manager.onClientMessage (/Users/niallo/projects/strider-14/strider/node_modules/socket.io/lib/manager.js:488:38)
at WebSocket.Transport.onMessage (/Users/niallo/projects/strider-14/strider/node_modules/socket.io/lib/transport.js:387:20)
View gist:6768589
30 Sep 12:08:50 - error: Job 5249cc41f2b60ba388000008 Command failed with code 128 Error: Command failed with code 128
at badCode (/Users/niallo/projects/strider-14/strider/node_modules/strider-github/node_modules/strider-git/worker.js:46:11)
at /Users/niallo/projects/strider-14/strider/node_modules/strider-github/node_modules/strider-git/worker.js:66:35
at ChildProcess.<anonymous> (/Users/niallo/projects/strider-14/strider/node_modules/strider-simple-runner/node_modules/strider-runner-core/lib/job.js:181:7)
at ChildProcess.EventEmitter.emit (events.js:98:17)
at maybeClose (child_process.js:735:16)
at Socket.<anonymous> (child_process.js:948:11)
at Socket.EventEmitter.emit (events.js:95:17)
at Pipe.close (net.js:466:12)
View gist:6768432
TypeError: Cannot read property 'id' of undefined
at Object.Job (/Users/niallo/projects/strider-14/strider/node_modules/strider-simple-runner/node_modules/strider-runner-core/lib/job.js:37:21)
at Object.process [as processJob] (/Users/niallo/projects/strider-14/strider/node_modules/strider-simple-runner/node_modules/strider-runner-core/lib/index.js:19:13)
View gist:6768014
30 Sep 11:29:11 - info: Express server listening on port 3000 in development mode
/Users/niallo/projects/strider-14/strider/node_modules/mongoose/lib/utils.js:419
throw err;
^
TypeError: Cannot read property 'providers' of undefined
at striderJson (/Users/niallo/projects/strider-14/strider/lib/backchannel.js:94:20)
at /Users/niallo/projects/strider-14/strider/lib/backchannel.js:131:7
at Promise.<anonymous> (/Users/niallo/projects/strider-14/strider/node_modules/mongoose/lib/model.js:1408:21)
at Promise.<anonymous> (/Users/niallo/projects/strider-14/strider/node_modules/mongoose/node_modules/mpromise/lib/promise.js:162:8)
View gist:6767665
> strider@1.4.0-pre start /Users/niallo/projects/strider-14/strider
> bin/strider
30 Sep 11:02:16 - info: Using MongoDB URL: mongodb://localhost/strider-foss
30 Sep 11:02:17 - info: RUNNER INIT
/Users/niallo/projects/strider-14/strider/node_modules/express/lib/router/index.js:290
throw new Error(msg);
^
Error: .get() requires callback functions but got a [object Undefined]
View gist:6766824
30 Sep 10:02:18 - info: initalized static directories
/Users/niallo/projects/strider-14/strider/node_modules/mongoose/lib/utils.js:419
throw err;
^
TypeError: Object.keys called on non-object
at Function.keys (native)
at /Users/niallo/projects/strider-14/strider/main.js:95:16
at /Users/niallo/projects/strider-14/strider/node_modules/mongoose/lib/utils.js:414:16
at /Users/niallo/projects/strider-14/strider/node_modules/mongoose/node_modules/mongodb/lib/mongodb/collection.js:497:9
View -tmp-worker.diff
diff --git a/index.js b/index.js
index d750ce4..9c89fc4 100644
--- a/index.js
+++ b/index.js
@@ -1,8 +1,9 @@
var Runner = require('./lib/worker')
var create = function(emitter, opts, cb){
+ console.dir(opts)
var runner = new Runner(emitter, opts)
@niallo
niallo / reconnect-mongoose.js
Last active Dec 17, 2015
Simple Mongoose program to facilitate testing MongoDB auto-reconnect in client
View reconnect-mongoose.js
//
// Program to query a local mongodb every second. This should auto-reconnect.
//
// Instructions:
//
// 1) start mongod
// 2) npm i mongoose@3.6.9 && node reconnect-mongoose.js
// 3) kill mongod
// 4) after a short interval, restart mongod
//
You can’t perform that action at this time.