Spaces:
Build error
Build error
File size: 471 Bytes
07ae658 2c58d43 07ae658 2c58d43 07ae658 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
const NodeMediaServer = require('node-media-server')
const config = {
/*
auth: {
api: true,
api_user: process.env.WEBTV_MEDIA_SERVER_USER,
api_pass: process.env.WEBTV_MEDIA_SERVER_PASSWORD
},
*/
rtmp: {
port: 1935,
chunk_size: 60000,
gop_cache: true,
ping: 30,
ping_timeout: 60
},
http: {
port: 8000,
allow_origin: '*'
}
};
console.log("starting the RTMP server..")
var nms = new NodeMediaServer(config)
nms.run() |