Add localhost c2s connections

This commit is contained in:
tytan652
2021-07-13 17:40:29 +02:00
parent 499ecffe62
commit 3b51bf2946
5 changed files with 64 additions and 3 deletions

View File

@ -168,10 +168,14 @@ class ProsodyConfigContent {
this.authenticated.set('http_auth_url', url)
}
usePeertubeBosh (prosodyDomain: string, port: string): void {
usePeertubeBosh (prosodyDomain: string, port: string, enableC2s: boolean, c2sPort: string): void {
this.global.set('c2s_require_encryption', false)
this.global.set('interfaces', ['127.0.0.1', '::1'])
this.global.set('c2s_ports', [])
if (enableC2s) {
this.global.set('c2s_ports', [c2sPort])
} else {
this.global.set('c2s_ports', [])
}
this.global.set('c2s_interfaces', ['127.0.0.1', '::1'])
this.global.set('s2s_ports', [])
this.global.set('s2s_interfaces', ['127.0.0.1', '::1'])