···161161162162<!-- TODO(@maralorn) Link to package set generation docs in the contributors guide below. -->
163163164164+### GHC Deprecation Policy {#ghc-deprecation-policy}
165165+166166+We remove GHC versions according to the following policy:
167167+168168+#### Major GHC versions {#major-ghc-deprecation}
169169+170170+We keep the following GHC major versions:
171171+1. The current Stackage LTS as the default and all later major versions.
172172+2. The two latest major versions older than our default.
173173+3. The currently recommended GHCup version and all later major versions.
174174+175175+Older GHC versions might be kept longer, if there are in-tree consumers. We will coordinate with the maintainers of those dependencies to find a way forward.
176176+177177+#### Minor GHC versions {#minor-ghc-deprecation}
178178+179179+Every major version has a default minor version. The default minor version will be updated as soon as viable without breakage.
180180+181181+Older minor versions for a supported major version will only be kept, if they are the last supported version of a major Stackage LTS release.
182182+183183+<!-- Policy introduced here: https://discourse.nixos.org/t/nixpkgs-ghc-deprecation-policy-user-feedback-necessary/64153 -->
184184+164185## `haskellPackages.mkDerivation` {#haskell-mkderivation}
165186166187Every haskell package set has its own haskell-aware `mkDerivation` which is used
+8-4
doc/languages-frameworks/rust.section.md
···605605directory. In such cases, the `cargoRoot` attribute can be used to
606606specify the crate's directory relative to `sourceRoot`. In the
607607following example, the crate is in `src/rust`, as specified in the
608608-`cargoRoot` attribute. Note that we also need to specify the correct
609609-path for `fetchCargoVendor`.
608608+`cargoRoot` attribute. Note that we also need to pass in `cargoRoot`
609609+to `fetchCargoVendor`.
610610611611```nix
612612{
···627627 };
628628629629 cargoDeps = rustPlatform.fetchCargoVendor {
630630- inherit pname version src;
631631- sourceRoot = "${pname}-${version}/${cargoRoot}";
630630+ inherit
631631+ pname
632632+ version
633633+ src
634634+ cargoRoot
635635+ ;
632636 hash = "sha256-ctUt8maCjnGddKPf+Ii++wKsAXA1h+JM6zKQNXXwJqQ=";
633637 };
634638
···13131414<!-- To avoid merge conflicts, consider adding your item at an arbitrary place in the list instead. -->
15151616-- The `boot.readOnlyNixStore` has been removed. Control over bind mount options on `/nix/store` is now offered by the `boot.nixStoreMountOpts` option.
1616+- The `offrss` package was removed due to lack of upstream maintenance since 2012. It's recommended for users to migrate to another RSS reader
17171818## Other Notable Changes {#sec-nixpkgs-release-25.11-notable-changes}
1919
···30303131- `renovate` was updated to v40. See the [upstream release notes](https://github.com/renovatebot/renovate/releases/tag/40.0.0) for breaking changes.
32323333+- The `boot.readOnlyNixStore` has been removed. Control over bind mount options on `/nix/store` is now offered by the `boot.nixStoreMountOpts` option.
3434+3335## Other Notable Changes {#sec-release-25.11-notable-changes}
34363537<!-- To avoid merge conflicts, consider adding your item at an arbitrary place in the list instead. -->
···2323 ;
24242525 finalPackage = cfg.package.overridePythonAttrs (oldAttrs: {
2626- propagatedBuildInputs =
2727- oldAttrs.propagatedBuildInputs
2626+ dependencies =
2727+ oldAttrs.dependencies
2828 # for audio enhancements like auto-gain, noise suppression
2929 ++ cfg.package.optional-dependencies.webrtc
3030 # vad is currently optional, because it is broken on aarch64-linux
+31
nixos/modules/services/networking/dsnet.md
···11+# dsnet {#module-services-dsnet}
22+33+dsnet is a CLI tool to manage a centralised wireguard server. It allows easy
44+generation of client configuration, handling key generation, IP allocation etc.
55+66+It keeps its own configuration at `/etc/dsnetconfig.json`, which is more of a
77+database. It contains key material too.
88+99+The way this module works is to patch this database with whatever is configured
1010+in the nix service instantiation. This happens automatically when required.
1111+1212+This way it is possible to decide what to let dnset manage and what parts you
1313+want to keep declaratively.
1414+1515+```
1616+services.dsnet = {
1717+ enable = true;
1818+ settings = {
1919+ ExternalHostname = "vpn.example.com";
2020+ Network = "10.171.90.0/24";
2121+ Network6 = "";
2222+ IP = "10.171.90.1";
2323+ IP6 = "";
2424+ DNS = "10.171.90.1";
2525+ Networks = [ "0.0.0.0/0" ];
2626+ };
2727+2828+```
2929+3030+3131+See <https://github.com/naggie/dsnet> for more information.
+184
nixos/modules/services/networking/dsnet.nix
···11+{
22+ config,
33+ lib,
44+ pkgs,
55+ ...
66+}:
77+88+let
99+ cfg = config.services.dsnet;
1010+ settingsFormat = pkgs.formats.json { };
1111+ patchFile = settingsFormat.generate "dsnet-patch.json" cfg.settings;
1212+in
1313+{
1414+ options.services.dsnet = {
1515+ enable = lib.mkEnableOption "dsnet, a centralised Wireguard VPN manager";
1616+1717+ package = lib.mkPackageOption pkgs "dsnet" { };
1818+1919+ settings = lib.mkOption {
2020+ type = lib.types.submodule {
2121+2222+ freeformType = settingsFormat.type;
2323+2424+ options = {
2525+ ExternalHostname = lib.mkOption {
2626+ type = lib.types.nullOr lib.types.str;
2727+ default = null;
2828+ example = "vpn.example.com";
2929+ description = ''
3030+ The hostname that clients should use to connect to this server.
3131+ This is used to generate the client configuration files.
3232+3333+ This is preferred over ExternalIP, as it allows for IPv4 and
3434+ IPv6, as well as enabling the ability tp change IP.
3535+ '';
3636+ };
3737+3838+ ExternalIP = lib.mkOption {
3939+ type = lib.types.nullOr lib.types.str;
4040+ default = null;
4141+ example = "192.0.2.1";
4242+ description = ''
4343+ The external IP address of the server. This is used to generate
4444+ the client configuration files for when an ExternalHostname is not set.
4545+4646+ Leaving this empty will cause dsnet to use the IP address of
4747+ what looks like the WAN interface.
4848+ '';
4949+ };
5050+5151+ ExternalIP6 = lib.mkOption {
5252+ type = lib.types.nullOr lib.types.str;
5353+ default = null;
5454+ example = "2001:db8::1";
5555+ description = ''
5656+ The external IPv6 address of the server. This is used to generate
5757+ the client configuration files for when an ExternalHostname is
5858+ not set. Used in preference to ExternalIP.
5959+6060+ Leaving this empty will cause dsnet to use the IP address of
6161+ what looks like the WAN interface.
6262+ '';
6363+ };
6464+6565+ Network = lib.mkOption {
6666+ type = lib.types.nullOr lib.types.str;
6767+ default = null;
6868+ example = "172.18.0.0/24";
6969+ description = ''
7070+ The IPv4 network that the server will use to allocate IPs on the network.
7171+ Leave this empty to let dsnet choose a network.
7272+ '';
7373+ };
7474+7575+ Network6 = lib.mkOption {
7676+ type = lib.types.nullOr lib.types.str;
7777+ default = null;
7878+ example = "2001:db8::1/64";
7979+ description = ''
8080+ The IPv6 network that the server will use to allocate IPs on the
8181+ network.
8282+ Leave this empty to let dsnet choose a network.
8383+ '';
8484+ };
8585+8686+ IP = lib.mkOption {
8787+ type = lib.types.nullOr lib.types.str;
8888+ default = null;
8989+ example = "172.18.0.1";
9090+ description = ''
9191+ The IPv4 address that the server will use on the network.
9292+ Leave this empty to let dsnet choose an address.
9393+ '';
9494+ };
9595+9696+ IP6 = lib.mkOption {
9797+ type = lib.types.nullOr lib.types.str;
9898+ default = null;
9999+ example = "2001:db8::1";
100100+ description = ''
101101+ The IPv6 address that the server will use on the network
102102+ Leave this empty to let dsnet choose an address.
103103+ '';
104104+ };
105105+106106+ Networks = lib.mkOption {
107107+ type = lib.types.nullOr (lib.types.listOf lib.types.str);
108108+ default = null;
109109+ example = [
110110+ "0.0.0.0/0"
111111+ "192.168.0.0/24"
112112+ ];
113113+ description = ''
114114+ The CIDR networks that should route through this server. Clients
115115+ will be configured to route traffic for these networks through
116116+ the server peer.
117117+ '';
118118+ };
119119+ };
120120+ };
121121+122122+ default = { };
123123+ description = ''
124124+ The settings to use for dsnet. This will be converted to a JSON
125125+ object that will be passed to dsnet as a patch, using the patch
126126+ command when the service is started. See the dsnet documentation for
127127+ more information on the additional options.
128128+129129+ Note that the resulting /etc/dsnetconfg.json is more of a database
130130+ than it is a configuration file. It is therefore recommended that
131131+ system specific values are configured here, rather than the full
132132+ configuration including peers.
133133+134134+ Peers may be managed via the dsnet add/remove commands, negating the
135135+ need to manage key material and cumbersom configuration with nix. If
136136+ you want peer configuration in nix, you may as well use the regular
137137+ wireguard module.
138138+ '';
139139+ example = {
140140+ ExternalHostname = "vpn.example.com";
141141+ ExternalIP = "127.0.0.1";
142142+ ExternalIP6 = "";
143143+ ListenPort = 51820;
144144+ Network = "10.3.148.0/22";
145145+ Network6 = "";
146146+ IP = "10.3.148.1";
147147+ IP6 = "";
148148+ DNS = "8.8.8.8";
149149+ Networks = [ "0.0.0.0/0" ];
150150+ };
151151+ };
152152+ };
153153+154154+ config = lib.mkIf cfg.enable {
155155+ environment.systemPackages = [ cfg.package ];
156156+157157+ systemd.services.dsnet = {
158158+ description = "dsnet VPN Management";
159159+ after = [ "network-online.target" ];
160160+ wants = [ "network-online.target" ];
161161+ wantedBy = [ "multi-user.target" ];
162162+ preStart = ''
163163+ test ! -f /etc/dsnetconfig.json && ${lib.getExe cfg.package} init
164164+ ${lib.getExe cfg.package} patch < ${patchFile}
165165+ '';
166166+ serviceConfig = {
167167+ ExecStart = "${lib.getExe cfg.package} up";
168168+ ExecStop = "${lib.getExe cfg.package} down";
169169+ Type = "oneshot";
170170+ # consider the service to be active after process exits, so it can be
171171+ # reloaded
172172+ RemainAfterExit = true;
173173+ };
174174+175175+ reload = ''
176176+ ${lib.getExe cfg.package} patch < ${patchFile}
177177+ ${lib.getExe cfg.package} sync < ${patchFile}
178178+ '';
179179+180180+ # reload _instead_ of restarting on change
181181+ reloadIfChanged = true;
182182+ };
183183+ };
184184+}
+99-127
nixos/modules/services/networking/murmur.nix
···55 ...
66}:
7788-with lib;
99-108let
119 cfg = config.services.murmur;
1210 forking = cfg.logFile != null;
···1412 database=${cfg.stateDir}/murmur.sqlite
1513 dbDriver=QSQLITE
16141717- autobanAttempts=${toString cfg.autobanAttempts}
1818- autobanTimeframe=${toString cfg.autobanTimeframe}
1919- autobanTime=${toString cfg.autobanTime}
1515+ autobanAttempts=${lib.toString cfg.autobanAttempts}
1616+ autobanTimeframe=${lib.toString cfg.autobanTimeframe}
1717+ autobanTime=${lib.toString cfg.autobanTime}
20182121- logfile=${optionalString (cfg.logFile != null) cfg.logFile}
2222- ${optionalString forking "pidfile=/run/murmur/murmurd.pid"}
1919+ logfile=${lib.optionalString (cfg.logFile != null) cfg.logFile}
2020+ ${lib.optionalString forking "pidfile=/run/murmur/murmurd.pid"}
23212422 welcometext="${cfg.welcometext}"
2525- port=${toString cfg.port}
2323+ port=${lib.toString cfg.port}
26242727- ${optionalString (cfg.hostName != "") "host=${cfg.hostName}"}
2828- ${optionalString (cfg.password != "") "serverpassword=${cfg.password}"}
2525+ ${lib.optionalString (cfg.hostName != "") "host=${cfg.hostName}"}
2626+ ${lib.optionalString (cfg.password != "") "serverpassword=${cfg.password}"}
29273030- bandwidth=${toString cfg.bandwidth}
3131- users=${toString cfg.users}
2828+ bandwidth=${lib.toString cfg.bandwidth}
2929+ users=${lib.toString cfg.users}
32303333- textmessagelength=${toString cfg.textMsgLength}
3434- imagemessagelength=${toString cfg.imgMsgLength}
3535- allowhtml=${boolToString cfg.allowHtml}
3636- logdays=${toString cfg.logDays}
3737- bonjour=${boolToString cfg.bonjour}
3838- sendversion=${boolToString cfg.sendVersion}
3131+ textmessagelength=${lib.toString cfg.textMsgLength}
3232+ imagemessagelength=${lib.toString cfg.imgMsgLength}
3333+ allowhtml=${lib.boolToString cfg.allowHtml}
3434+ logdays=${lib.toString cfg.logDays}
3535+ bonjour=${lib.boolToString cfg.bonjour}
3636+ sendversion=${lib.boolToString cfg.sendVersion}
39374040- ${optionalString (cfg.registerName != "") "registerName=${cfg.registerName}"}
4141- ${optionalString (cfg.registerPassword != "") "registerPassword=${cfg.registerPassword}"}
4242- ${optionalString (cfg.registerUrl != "") "registerUrl=${cfg.registerUrl}"}
4343- ${optionalString (cfg.registerHostname != "") "registerHostname=${cfg.registerHostname}"}
3838+ ${lib.optionalString (cfg.registerName != "") "registerName=${cfg.registerName}"}
3939+ ${lib.optionalString (cfg.registerPassword != "") "registerPassword=${cfg.registerPassword}"}
4040+ ${lib.optionalString (cfg.registerUrl != "") "registerUrl=${cfg.registerUrl}"}
4141+ ${lib.optionalString (cfg.registerHostname != "") "registerHostname=${cfg.registerHostname}"}
44424545- certrequired=${boolToString cfg.clientCertRequired}
4646- ${optionalString (cfg.sslCert != "") "sslCert=${cfg.sslCert}"}
4747- ${optionalString (cfg.sslKey != "") "sslKey=${cfg.sslKey}"}
4848- ${optionalString (cfg.sslCa != "") "sslCA=${cfg.sslCa}"}
4343+ certrequired=${lib.boolToString cfg.clientCertRequired}
4444+ ${lib.optionalString (cfg.sslCert != "") "sslCert=${cfg.sslCert}"}
4545+ ${lib.optionalString (cfg.sslKey != "") "sslKey=${cfg.sslKey}"}
4646+ ${lib.optionalString (cfg.sslCa != "") "sslCA=${cfg.sslCa}"}
49475050- ${optionalString (cfg.dbus != null) "dbus=${cfg.dbus}"}
4848+ ${lib.optionalString (cfg.dbus != null) "dbus=${cfg.dbus}"}
51495250 ${cfg.extraConfig}
5351 '';
5452in
5553{
5656- imports = [
5757- (mkRenamedOptionModule [ "services" "murmur" "welcome" ] [ "services" "murmur" "welcometext" ])
5858- (mkRemovedOptionModule [ "services" "murmur" "pidfile" ] "Hardcoded to /run/murmur/murmurd.pid now")
5959- ];
6060-6154 options = {
6255 services.murmur = {
6363- enable = mkOption {
6464- type = types.bool;
6565- default = false;
6666- description = "If enabled, start the Murmur Mumble server.";
6767- };
5656+ enable = lib.mkEnableOption "Mumble server";
68576969- openFirewall = mkOption {
7070- type = types.bool;
7171- default = false;
7272- description = ''
7373- Open ports in the firewall for the Murmur Mumble server.
7474- '';
7575- };
5858+ openFirewall = lib.mkEnableOption "opening ports in the firewall for the Mumble server";
76597777- user = mkOption {
7878- type = types.str;
6060+ user = lib.mkOption {
6161+ type = lib.types.str;
7962 default = "murmur";
8063 description = ''
8164 The name of an existing user to use to run the service.
···8366 '';
8467 };
85688686- group = mkOption {
8787- type = types.str;
6969+ group = lib.mkOption {
7070+ type = lib.types.str;
8871 default = "murmur";
8972 description = ''
9073 The name of an existing group to use to run the service.
···9275 '';
9376 };
94779595- stateDir = mkOption {
9696- type = types.path;
7878+ stateDir = lib.mkOption {
7979+ type = lib.types.path;
9780 default = "/var/lib/murmur";
9881 description = ''
9982 Directory to store data for the server.
10083 '';
10184 };
10285103103- autobanAttempts = mkOption {
104104- type = types.int;
8686+ autobanAttempts = lib.mkOption {
8787+ type = lib.types.int;
10588 default = 10;
10689 description = ''
10790 Number of attempts a client is allowed to make in
···11093 '';
11194 };
11295113113- autobanTimeframe = mkOption {
114114- type = types.int;
9696+ autobanTimeframe = lib.mkOption {
9797+ type = lib.types.int;
11598 default = 120;
11699 description = ''
117100 Timeframe in which a client can connect without being banned
···119102 '';
120103 };
121104122122- autobanTime = mkOption {
123123- type = types.int;
105105+ autobanTime = lib.mkOption {
106106+ type = lib.types.int;
124107 default = 300;
125108 description = "The amount of time an IP ban lasts (in seconds).";
126109 };
127110128128- logFile = mkOption {
129129- type = types.nullOr types.path;
111111+ logFile = lib.mkOption {
112112+ type = lib.types.nullOr lib.types.path;
130113 default = null;
131114 example = "/var/log/murmur/murmurd.log";
132115 description = "Path to the log file for Murmur daemon. Empty means log to journald.";
133116 };
134117135135- welcometext = mkOption {
136136- type = types.str;
118118+ welcometext = lib.mkOption {
119119+ type = lib.types.str;
137120 default = "";
138121 description = "Welcome message for connected clients.";
139122 };
140123141141- port = mkOption {
142142- type = types.port;
124124+ port = lib.mkOption {
125125+ type = lib.types.port;
143126 default = 64738;
144127 description = "Ports to bind to (UDP and TCP).";
145128 };
146129147147- hostName = mkOption {
148148- type = types.str;
130130+ hostName = lib.mkOption {
131131+ type = lib.types.str;
149132 default = "";
150133 description = "Host to bind to. Defaults binding on all addresses.";
151134 };
152135153153- package = mkPackageOption pkgs "murmur" { };
136136+ package = lib.mkPackageOption pkgs "murmur" { };
154137155155- password = mkOption {
156156- type = types.str;
138138+ password = lib.mkOption {
139139+ type = lib.types.str;
157140 default = "";
158141 description = "Required password to join server, if specified.";
159142 };
160143161161- bandwidth = mkOption {
162162- type = types.int;
144144+ bandwidth = lib.mkOption {
145145+ type = lib.types.int;
163146 default = 72000;
164147 description = ''
165148 Maximum bandwidth (in bits per second) that clients may send
···167150 '';
168151 };
169152170170- users = mkOption {
171171- type = types.int;
153153+ users = lib.mkOption {
154154+ type = lib.types.int;
172155 default = 100;
173156 description = "Maximum number of concurrent clients allowed.";
174157 };
175158176176- textMsgLength = mkOption {
177177- type = types.int;
159159+ textMsgLength = lib.mkOption {
160160+ type = lib.types.int;
178161 default = 5000;
179162 description = "Max length of text messages. Set 0 for no limit.";
180163 };
181164182182- imgMsgLength = mkOption {
183183- type = types.int;
165165+ imgMsgLength = lib.mkOption {
166166+ type = lib.types.int;
184167 default = 131072;
185168 description = "Max length of image messages. Set 0 for no limit.";
186169 };
187170188188- allowHtml = mkOption {
189189- type = types.bool;
171171+ allowHtml = lib.mkOption {
172172+ type = lib.types.bool;
190173 default = true;
191174 description = ''
192175 Allow HTML in client messages, comments, and channel
···194177 '';
195178 };
196179197197- logDays = mkOption {
198198- type = types.int;
180180+ logDays = lib.mkOption {
181181+ type = lib.types.int;
199182 default = 31;
200183 description = ''
201184 How long to store RPC logs for in the database. Set 0 to
···203186 '';
204187 };
205188206206- bonjour = mkOption {
207207- type = types.bool;
208208- default = false;
209209- description = ''
210210- Enable Bonjour auto-discovery, which allows clients over
211211- your LAN to automatically discover Murmur servers.
212212- '';
213213- };
189189+ bonjour = lib.mkEnableOption "Bonjour auto-discovery, which allows clients over your LAN to automatically discover Mumble servers";
214190215215- sendVersion = mkOption {
216216- type = types.bool;
191191+ sendVersion = lib.mkOption {
192192+ type = lib.types.bool;
217193 default = true;
218194 description = "Send Murmur version in UDP response.";
219195 };
220196221221- registerName = mkOption {
222222- type = types.str;
197197+ registerName = lib.mkOption {
198198+ type = lib.types.str;
223199 default = "";
224200 description = ''
225201 Public server registration name, and also the name of the
···228204 '';
229205 };
230206231231- registerPassword = mkOption {
232232- type = types.str;
207207+ registerPassword = lib.mkOption {
208208+ type = lib.types.str;
233209 default = "";
234210 description = ''
235211 Public server registry password, used authenticate your
···238214 '';
239215 };
240216241241- registerUrl = mkOption {
242242- type = types.str;
217217+ registerUrl = lib.mkOption {
218218+ type = lib.types.str;
243219 default = "";
244220 description = "URL website for your server.";
245221 };
246222247247- registerHostname = mkOption {
248248- type = types.str;
223223+ registerHostname = lib.mkOption {
224224+ type = lib.types.str;
249225 default = "";
250226 description = ''
251227 DNS hostname where your server can be reached. This is only
···255231 '';
256232 };
257233258258- clientCertRequired = mkOption {
259259- type = types.bool;
260260- default = false;
261261- description = "Require clients to authenticate via certificates.";
262262- };
234234+ clientCertRequired = lib.mkEnableOption "requiring clients to authenticate via certificates";
263235264264- sslCert = mkOption {
265265- type = types.str;
236236+ sslCert = lib.mkOption {
237237+ type = lib.types.str;
266238 default = "";
267239 description = "Path to your SSL certificate.";
268240 };
269241270270- sslKey = mkOption {
271271- type = types.str;
242242+ sslKey = lib.mkOption {
243243+ type = lib.types.str;
272244 default = "";
273245 description = "Path to your SSL key.";
274246 };
275247276276- sslCa = mkOption {
277277- type = types.str;
248248+ sslCa = lib.mkOption {
249249+ type = lib.types.str;
278250 default = "";
279251 description = "Path to your SSL CA certificate.";
280252 };
281253282282- extraConfig = mkOption {
283283- type = types.lines;
254254+ extraConfig = lib.mkOption {
255255+ type = lib.types.lines;
284256 default = "";
285257 description = "Extra configuration to put into murmur.ini.";
286258 };
287259288288- environmentFile = mkOption {
289289- type = types.nullOr types.path;
260260+ environmentFile = lib.mkOption {
261261+ type = lib.types.nullOr lib.types.path;
290262 default = null;
291291- example = literalExpression ''"''${config.services.murmur.stateDir}/murmurd.env"'';
263263+ example = lib.literalExpression ''"''${config.services.murmur.stateDir}/murmurd.env"'';
292264 description = ''
293265 Environment file as defined in {manpage}`systemd.exec(5)`.
294266···311283 '';
312284 };
313285314314- dbus = mkOption {
315315- type = types.enum [
286286+ dbus = lib.mkOption {
287287+ type = lib.types.enum [
316288 null
317289 "session"
318290 "system"
···323295 };
324296 };
325297326326- config = mkIf cfg.enable {
327327- users.users.murmur = mkIf (cfg.user == "murmur") {
298298+ config = lib.mkIf cfg.enable {
299299+ users.users.murmur = lib.mkIf (cfg.user == "murmur") {
328300 description = "Murmur Service user";
329301 home = cfg.stateDir;
330302 createHome = true;
331303 uid = config.ids.uids.murmur;
332304 group = cfg.group;
333305 };
334334- users.groups.murmur = mkIf (cfg.group == "murmur") {
306306+ users.groups.murmur = lib.mkIf (cfg.group == "murmur") {
335307 gid = config.ids.gids.murmur;
336308 };
337309338338- networking.firewall = mkIf cfg.openFirewall {
310310+ networking.firewall = lib.mkIf cfg.openFirewall {
339311 allowedTCPPorts = [ cfg.port ];
340312 allowedUDPPorts = [ cfg.port ];
341313 };
···353325 serviceConfig = {
354326 # murmurd doesn't fork when logging to the console.
355327 Type = if forking then "forking" else "simple";
356356- PIDFile = mkIf forking "/run/murmur/murmurd.pid";
357357- EnvironmentFile = mkIf (cfg.environmentFile != null) cfg.environmentFile;
328328+ PIDFile = lib.mkIf forking "/run/murmur/murmurd.pid";
329329+ EnvironmentFile = lib.mkIf (cfg.environmentFile != null) cfg.environmentFile;
358330 ExecStart = "${cfg.package}/bin/mumble-server -ini /run/murmur/murmurd.ini";
359331 Restart = "always";
360332 RuntimeDirectory = "murmur";
···390362391363 # currently not included in upstream package, addition requested at
392364 # https://github.com/mumble-voip/mumble/issues/6078
393393- services.dbus.packages = mkIf (cfg.dbus == "system") [
365365+ services.dbus.packages = lib.mkIf (cfg.dbus == "system") [
394366 (pkgs.writeTextFile {
395367 name = "murmur-dbus-policy";
396368 text = ''
···432404 r /run/murmur/murmurd.ini,
433405 r ${configFile},
434406 ''
435435- + optionalString (cfg.logFile != null) ''
407407+ + lib.optionalString (cfg.logFile != null) ''
436408 rw ${cfg.logFile},
437409 ''
438438- + optionalString (cfg.sslCert != "") ''
410410+ + lib.optionalString (cfg.sslCert != "") ''
439411 r ${cfg.sslCert},
440412 ''
441441- + optionalString (cfg.sslKey != "") ''
413413+ + lib.optionalString (cfg.sslKey != "") ''
442414 r ${cfg.sslKey},
443415 ''
444444- + optionalString (cfg.sslCa != "") ''
416416+ + lib.optionalString (cfg.sslCa != "") ''
445417 r ${cfg.sslCa},
446418 ''
447447- + optionalString (cfg.dbus != null) ''
419419+ + lib.optionalString (cfg.dbus != null) ''
448420 dbus bus=${cfg.dbus}
449421 ''
450422 + ''
+7-6
nixos/modules/services/web-apps/lasuite-docs.nix
···99 inherit (lib)
1010 getExe
1111 mapAttrs
1212+ match
1213 mkEnableOption
1314 mkIf
1415 mkPackageOption
···3132 else
3233 toString value
3334 ) cfg.settings;
3535+3636+ proxySuffix = if match "unix:.*" cfg.bind != null then ":" else "";
34373538 commonServiceConfig = {
3639 RuntimeDirectory = "lasuite-docs";
···264267 type = types.str;
265268 default = if cfg.enableNginx then "localhost,127.0.0.1,${cfg.domain}" else "";
266269 defaultText = lib.literalExpression ''
267267- if cfg.enableNginx then "localhost,127.0.0.1,$${cfg.domain}" else ""
270270+ if cfg.enableNginx then "localhost,127.0.0.1,''${cfg.domain}" else ""
268271 '';
269272 description = "Comma-separated list of hosts that are able to connect to the server";
270273 };
···348351 wantedBy = [ "multi-user.target" ];
349352350353 preStart = ''
351351- ln -sfT ${cfg.backendPackage}/share/static /var/lib/lasuite-docs/static
352352-353354 if [ ! -f .version ]; then
354355 touch .version
355356 fi
···371372 environment = pythonEnvironment;
372373373374 serviceConfig = {
375375+ BindReadOnlyPaths = "${cfg.backendPackage}/share/static:/var/lib/lasuite-docs/static";
376376+374377 ExecStart = utils.escapeSystemdExecArgs (
375378 [
376379 (lib.getExe' cfg.backendPackage "gunicorn")
···476479 };
477480478481 locations."/media-auth" = {
479479- proxyPass = "http://${cfg.bind}";
482482+ proxyPass = "http://${cfg.bind}${proxySuffix}/api/v1.0/documents/media-auth/";
480483 recommendedProxySettings = true;
481484 extraConfig = ''
482482- rewrite $/(.*)^ /api/v1.0/documents/$1 break;
483485 proxy_set_header X-Original-URL $request_uri;
484486 proxy_pass_request_body off;
485487 proxy_set_header Content-Length "";
···489491490492 locations."/media/" = {
491493 proxyPass = cfg.s3Url;
492492- recommendedProxySettings = true;
493494 extraConfig = ''
494495 auth_request /media-auth;
495496 auth_request_set $authHeader $upstream_http_authorization;
+2-2
nixos/tests/minio.nix
···82828383 # Create a test bucket on the server
8484 machine.succeed(
8585- "mc config host add minio http://localhost:9000 ${accessKey} ${secretKey} --api s3v4"
8585+ "mc alias set minio http://localhost:9000 ${accessKey} ${secretKey} --api s3v4"
8686 )
8787 machine.succeed("mc mb minio/test-bucket")
8888 machine.succeed("${minioPythonScript}")
···101101102102 # Create a test bucket on the server
103103 machine.succeed(
104104- "mc config host add minio https://localhost:9000 ${accessKey} ${secretKey} --api s3v4"
104104+ "mc alias set minio https://localhost:9000 ${accessKey} ${secretKey} --api s3v4"
105105 )
106106 machine.succeed("mc --insecure mb minio/test-bucket")
107107 machine.succeed("${minioPythonScript} tls")
···13911391 oauth2_proxy = throw "'oauth2_proxy' has been renamed to/replaced by 'oauth2-proxy'"; # Converted to throw 2024-10-17
13921392 ocis-bin = throw "ocis-bin has been renamed to ocis_5-bin'. Future major.minor versions will be made available as separate packages"; # Added 2025-03-30
13931393 odoo15 = throw "odoo15 has been removed from nixpkgs as it is unsupported; migrate to a newer version of odoo"; # Added 2025-05-06
13941394+ offrss = throw "offrss has been removed due to lack of upstream maintenance; consider using another rss reader"; # Added 2025-06-01
13941395 oil = lib.warnOnInstantiate "Oil has been replaced with the faster native C++ version and renamed to 'oils-for-unix'. See also https://github.com/oils-for-unix/oils/wiki/Oils-Deployments" oils-for-unix; # Added 2024-10-22
13951396 onevpl-intel-gpu = lib.warnOnInstantiate "onevpl-intel-gpu has been renamed to vpl-gpu-rt" vpl-gpu-rt; # Added 2024-06-04
13961397 openai-whisper-cpp = whisper-cpp; # Added 2024-12-13