mirror of
https://github.com/DeviceFarmer/stf.git
synced 2026-04-18 16:13:24 +02:00
Move support plugins to their own folder.
This commit is contained in:
19
lib/roles/device/support/push.js
Normal file
19
lib/roles/device/support/push.js
Normal file
@@ -0,0 +1,19 @@
|
||||
var syrup = require('syrup')
|
||||
|
||||
var zmq = require('zmq')
|
||||
|
||||
var logger = require('../../../util/logger')
|
||||
|
||||
module.exports = syrup()
|
||||
.define(function(options) {
|
||||
var log = logger.createLogger('device:plugins:push')
|
||||
|
||||
// Output
|
||||
var push = zmq.socket('push')
|
||||
options.endpoints.push.forEach(function(endpoint) {
|
||||
log.info('Sending output to %s', endpoint)
|
||||
push.connect(endpoint)
|
||||
})
|
||||
|
||||
return push
|
||||
})
|
||||
Reference in New Issue
Block a user