From c742c8fb7a62cf26a5efb5e20f58f5bcc2fb2a10 Mon Sep 17 00:00:00 2001 From: william Date: Mon, 25 Apr 2016 16:56:57 -0400 Subject: [PATCH] load stuff --- routes/api.js | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/routes/api.js b/routes/api.js index 3bd117e..5b3491e 100644 --- a/routes/api.js +++ b/routes/api.js @@ -162,11 +162,7 @@ router.post('/run/:ip?', function doRun(req, res, next){ if(found){ return runner(req, res, ip) }else{ - var name = 'crunner-'+(Math.random()*100).toString().replace('.',''); - return lxc.startEphemeral(name, 'crunner', function(data){ - ip2name[data.ip] = name; - return runner(req, res, data.ip); - }); + return runner(req, res, availContainers.pop()); } });