services.siproxd: drop

This is a followup to #408361 which removed siproxd. This change made
the module unusable due to the lack of the package argument.
This commit is contained in:
Charlotte 🦝 Deleńkec 2025-05-30 06:32:34 +01:00
parent d8d5ae4443
commit 62ab65aa5a
No known key found for this signature in database
GPG Key ID: AB2BD8DAF2E37122
4 changed files with 7 additions and 197 deletions

View File

@ -36,6 +36,8 @@
- The Pocket ID module ([`services.pocket-id`][#opt-services.pocket-id.enable]) and package (`pocket-id`) has been updated to 1.0.0. Some environment variables have been changed or removed, see the [migration guide](https://pocket-id.org/docs/setup/migrate-to-v1/).
- The `services.siproxd` module has been removed as `siproxd` is unmaintained and broken with libosip 5.x.
- `renovate` was updated to v40. See the [upstream release notes](https://github.com/renovatebot/renovate/releases/tag/40.0.0) for breaking changes.
## Other Notable Changes {#sec-release-25.11-notable-changes}

View File

@ -909,7 +909,6 @@
./services/misc/servarr/whisparr.nix
./services/misc/serviio.nix
./services/misc/sickbeard.nix
./services/misc/siproxd.nix
./services/misc/snapper.nix
./services/misc/soft-serve.nix
./services/misc/sourcehut

View File

@ -223,6 +223,11 @@ in
"services"
"shout"
] "shout was removed because it was deprecated upstream in favor of thelounge.")
(mkRemovedOptionModule [ "services" "siproxd" ] ''
The siproxd package and the corresponding module have been removed due to
the service being unmaintained. `services.asterisk.*` or `services.freeswitch.*`
could be used instead.
'')
(mkRemovedOptionModule [ "services" "ssmtp" ] ''
The ssmtp package and the corresponding module have been removed due to
the program being unmaintained. The options `programs.msmtp.*` can be

View File

@ -1,196 +0,0 @@
{
config,
lib,
pkgs,
...
}:
let
cfg = config.services.siproxd;
conf = ''
daemonize = 0
rtp_proxy_enable = 1
user = siproxd
if_inbound = ${cfg.ifInbound}
if_outbound = ${cfg.ifOutbound}
sip_listen_port = ${toString cfg.sipListenPort}
rtp_port_low = ${toString cfg.rtpPortLow}
rtp_port_high = ${toString cfg.rtpPortHigh}
rtp_dscp = ${toString cfg.rtpDscp}
sip_dscp = ${toString cfg.sipDscp}
${lib.optionalString (
cfg.hostsAllowReg != [ ]
) "hosts_allow_reg = ${lib.concatStringsSep "," cfg.hostsAllowReg}"}
${lib.optionalString (
cfg.hostsAllowSip != [ ]
) "hosts_allow_sip = ${lib.concatStringsSep "," cfg.hostsAllowSip}"}
${lib.optionalString (
cfg.hostsDenySip != [ ]
) "hosts_deny_sip = ${lib.concatStringsSep "," cfg.hostsDenySip}"}
${lib.optionalString (cfg.passwordFile != "") "proxy_auth_pwfile = ${cfg.passwordFile}"}
${cfg.extraConfig}
'';
confFile = builtins.toFile "siproxd.conf" conf;
in
{
##### interface
options = {
services.siproxd = {
enable = lib.mkOption {
type = lib.types.bool;
default = false;
description = ''
Whether to enable the Siproxd SIP
proxy/masquerading daemon.
'';
};
ifInbound = lib.mkOption {
type = lib.types.str;
example = "eth0";
description = "Local network interface";
};
ifOutbound = lib.mkOption {
type = lib.types.str;
example = "ppp0";
description = "Public network interface";
};
hostsAllowReg = lib.mkOption {
type = lib.types.listOf lib.types.str;
default = [ ];
example = [
"192.168.1.0/24"
"192.168.2.0/24"
];
description = ''
Access control list for incoming SIP registrations.
'';
};
hostsAllowSip = lib.mkOption {
type = lib.types.listOf lib.types.str;
default = [ ];
example = [
"123.45.0.0/16"
"123.46.0.0/16"
];
description = ''
Access control list for incoming SIP traffic.
'';
};
hostsDenySip = lib.mkOption {
type = lib.types.listOf lib.types.str;
default = [ ];
example = [
"10.0.0.0/8"
"11.0.0.0/8"
];
description = ''
Access control list for denying incoming
SIP registrations and traffic.
'';
};
sipListenPort = lib.mkOption {
type = lib.types.int;
default = 5060;
description = ''
Port to listen for incoming SIP messages.
'';
};
rtpPortLow = lib.mkOption {
type = lib.types.int;
default = 7070;
description = ''
Bottom of UDP port range for incoming and outgoing RTP traffic
'';
};
rtpPortHigh = lib.mkOption {
type = lib.types.int;
default = 7089;
description = ''
Top of UDP port range for incoming and outgoing RTP traffic
'';
};
rtpTimeout = lib.mkOption {
type = lib.types.int;
default = 300;
description = ''
Timeout for an RTP stream. If for the specified
number of seconds no data is relayed on an active
stream, it is considered dead and will be killed.
'';
};
rtpDscp = lib.mkOption {
type = lib.types.int;
default = 46;
description = ''
DSCP (differentiated services) value to be assigned
to RTP packets. Allows QOS aware routers to handle
different types traffic with different priorities.
'';
};
sipDscp = lib.mkOption {
type = lib.types.int;
default = 0;
description = ''
DSCP (differentiated services) value to be assigned
to SIP packets. Allows QOS aware routers to handle
different types traffic with different priorities.
'';
};
passwordFile = lib.mkOption {
type = lib.types.str;
default = "";
description = ''
Path to per-user password file.
'';
};
extraConfig = lib.mkOption {
type = lib.types.lines;
default = "";
description = ''
Extra configuration to add to siproxd configuration.
'';
};
};
};
##### implementation
config = lib.mkIf cfg.enable {
users.users.siproxyd = {
uid = config.ids.uids.siproxd;
};
systemd.services.siproxd = {
description = "SIP proxy/masquerading daemon";
wantedBy = [ "multi-user.target" ];
after = [ "network.target" ];
serviceConfig = {
ExecStart = "${pkgs.siproxd}/sbin/siproxd -c ${confFile}";
};
};
};
}