pixel-streaming webrtc path updated to relative, webrtc test added

This commit is contained in:
C
2023-02-02 13:09:42 +05:00
parent b50c27ad10
commit f2febdfce8
3 changed files with 10 additions and 50 deletions
+9 -1
View File
@@ -1,4 +1,5 @@
var config = require('../config')
const config = require('../config')
const fs = require('fs')
const not_valid = (message) => {
console.error('not valid (config.js): ', message)
@@ -57,6 +58,13 @@ const test_config = () => {
config_pass = false
}
if (config.webrtc_server_path) {
if (!fs.existsSync(config.webrtc_server_path)) {
not_valid('wbertc_server_path exists in config BUT not in the filesystem (file not exists)')
config_pass = false
}
}
if (!config.app_args) {
not_valid('webrtc_server_path')
config_pass = false