Servicedock: Webgui for Docker Swarm. Manage Docker Swarm a a Service.
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
#!/usr/bin/node
|
|
|
|
|
|
|
|
var debug = require('debug')('ServiceDock')
|
|
|
|
var app = require('../app')
|
|
|
|
|
|
|
|
app.set('port', process.env.PORT || 4000)
|
|
|
|
|
|
|
|
var server = app.listen(app.get('port'), function() {
|
|
|
|
debug('Express server listening on port ' + server.address().port)
|
|
|
|
})
|
|
|
|
var io = require('socket.io').listen(server)
|
|
|
|
var docker = require('docker.js')(app, io, process.env.UPDATE_INTERVAL||10000, process.env.STATS_INTERVAL||10000)
|
|
|
|
|
|
|
|
io.sockets.on('connection', docker.connect)
|
|
|
|
debug('Socket server listening on port ' + server.address().port);
|
|
|
|
|
|
|
|
|