I can haz POST.

This commit is contained in:
Sebastian Tiedtke
2013-01-12 22:30:04 -08:00
parent 8cf1c039f8
commit ddf2a72fdf
2 changed files with 3 additions and 2 deletions

View File

@@ -80,8 +80,8 @@ while(runLoop) {
console.log("Executing command " + commandId + ": " + command);
var result = eval(command);
console.log("####"+commandId+"####"+result+"####");
var url = 'send_result/'+commandId+'/'+encodeURIComponent(result);
doCurl('GET', endpoint + url, null, function(err, res) {
var url = 'send_result/'+commandId;
doCurl('POST', endpoint + url, {result: result}, function(err, res) {
console.log("Sent result to server");
});
}

View File

@@ -11,6 +11,7 @@ var http = require('http')
, instruments = require('./instruments');
app.configure(function() {
app.use(express.bodyParser());
app.use(app.router);
});