mob next [ci-skip] [ci skip] [skip ci]
lastFile:modules/clan/phonebox/default.nix
This commit is contained in:
@@ -47,7 +47,6 @@ in
|
||||
domain = "localhost";
|
||||
dhcp-range = [
|
||||
"192.168.254.100,192.168.254.100,255.255.255.0,24h"
|
||||
"${ipv6Subnet}10,${ipv6Subnet}240,slaac"
|
||||
];
|
||||
dhcp-option = [
|
||||
"3,192.168.254.1"
|
||||
|
||||
@@ -11,6 +11,11 @@
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
let
|
||||
ata-interface = "";
|
||||
rtpPortFrom = 10000;
|
||||
rtpPortTo = 20000;
|
||||
in
|
||||
{
|
||||
networking.interfaces = {
|
||||
${ata-interface} = {
|
||||
@@ -37,7 +42,6 @@
|
||||
];
|
||||
dhcp-option = [
|
||||
"3,192.168.254.1"
|
||||
"option6:information-refresh-time,3600"
|
||||
];
|
||||
interface = [ ata-interface ];
|
||||
};
|
||||
@@ -56,8 +60,8 @@
|
||||
|
||||
networking.firewall.allowedUDPPortRanges = [
|
||||
{
|
||||
from = 10000;
|
||||
to = 20000;
|
||||
from = rtpPortFrom;
|
||||
to = rtpPortTo;
|
||||
}
|
||||
];
|
||||
|
||||
@@ -69,7 +73,6 @@
|
||||
networking.firewall.allowedTCPPorts = [
|
||||
53
|
||||
80
|
||||
443
|
||||
];
|
||||
|
||||
services.asterisk = {
|
||||
@@ -106,6 +109,12 @@
|
||||
exten => 8001,1,Dial(PJSIP/8001@kurogeek,20)
|
||||
'';
|
||||
|
||||
"rtp.conf" = ''
|
||||
[general]
|
||||
rtpstart=10000
|
||||
rtpend=20000
|
||||
'';
|
||||
|
||||
"pjsip.conf" = ''
|
||||
[transport-udp]
|
||||
type=transport
|
||||
@@ -116,6 +125,28 @@
|
||||
protocol=udp
|
||||
bind=::
|
||||
|
||||
[base_endpoint](!)
|
||||
type=endpoint
|
||||
disallow=all
|
||||
allow=ulaw,alaw,g722,gsm
|
||||
direct_media=no
|
||||
|
||||
[internal_endpoint](!,base_endpoint)
|
||||
context=from-internal
|
||||
|
||||
[external_endpoint](!,base_endpoint)
|
||||
context=from-external
|
||||
|
||||
[userpass_auth](!)
|
||||
type=auth
|
||||
auth_type=userpass
|
||||
|
||||
[ip_auth](!)
|
||||
type=identify
|
||||
endpoint=external
|
||||
|
||||
[dynamiic_aor](!)
|
||||
|
||||
[kurogeek]
|
||||
type=endpoint
|
||||
context=from-kurogeek
|
||||
|
||||
Reference in New Issue
Block a user