Skip to content
This repository was archived by the owner on Apr 12, 2021. It is now read-only.
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs-channels
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: a47962010dae
Choose a base ref
...
head repository: NixOS/nixpkgs-channels
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: bede9851a1c6
Choose a head ref
  • 6 commits
  • 4 files changed
  • 2 contributors

Commits on Jul 10, 2019

  1. nixos/syncthing: do not use nogroup

    We were already creating a group for the user under which to run syncthing but
    we were defaulting to running as `nogroup`.
    
    Additionally, use `install` instead of multiple calls to mkdir/cp/chown.
    peterhoeg committed Jul 10, 2019
    Copy the full SHA
    8317663 View commit details

Commits on Jul 20, 2019

  1. Copy the full SHA
    505df09 View commit details
  2. Copy the full SHA
    0fd6962 View commit details
  3. Copy the full SHA
    9b970d0 View commit details

Commits on Jul 24, 2019

  1. Merge pull request #64151 from aanderse/httpd-extraSubservices

    nixos/httpd: module cleanup
    aanderse authored Jul 24, 2019

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    72ef478 View commit details
  2. Merge pull request #65078 from peterhoeg/f/st

    nixos/syncthing: do not use nogroup
    peterhoeg authored Jul 24, 2019

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    bede985 View commit details
17 changes: 14 additions & 3 deletions nixos/doc/manual/release-notes/rl-1909.xml
Original file line number Diff line number Diff line change
@@ -149,9 +149,20 @@
</listitem>
<listitem>
<para>
Several of the apache subservices have been replaced with full NixOS
modules including LimeSurvey, WordPress, and Zabbix.
These modules can be enabled using the <option>services.limesurvey.enable</option>,
The httpd service no longer attempts to start the postgresql service. If you have come to depend
on this behaviour then you can preserve the behavior with the following configuration:
<literal>systemd.services.httpd.after = [ "postgresql.service" ];</literal>
</para>
<para>
The option <option>services.httpd.extraSubservices</option> has been
marked as deprecated. You may still use this feature, but it will be
removed in a future release of NixOS. You are encouraged to convert any
httpd subservices you may have written to a full NixOS module.
</para>
<para>
Most of the httpd subservices packaged with NixOS have been replaced with
full NixOS modules including LimeSurvey, WordPress, and Zabbix. These
modules can be enabled using the <option>services.limesurvey.enable</option>,
<option>services.wordpress.enable</option>, and <option>services.zabbixWeb.enable</option> options.
</para>
</listitem>
14 changes: 4 additions & 10 deletions nixos/modules/services/networking/syncthing.nix
Original file line number Diff line number Diff line change
@@ -291,7 +291,7 @@ in {

group = mkOption {
type = types.str;
default = "nogroup";
default = defaultUser;
description = ''
Syncthing will be run under this group (group will not be created if it doesn't exist.
This can be your user name).
@@ -403,18 +403,12 @@ in {
Group = cfg.group;
ExecStartPre = mkIf (cfg.declarative.cert != null || cfg.declarative.key != null)
"+${pkgs.writers.writeBash "syncthing-copy-keys" ''
mkdir -p ${cfg.configDir}
chown ${cfg.user}:${cfg.group} ${cfg.configDir}
chmod 700 ${cfg.configDir}
install -dm700 -o ${cfg.user} -g ${cfg.group} ${cfg.configDir}
${optionalString (cfg.declarative.cert != null) ''
cp ${toString cfg.declarative.cert} ${cfg.configDir}/cert.pem
chown ${cfg.user}:${cfg.group} ${cfg.configDir}/cert.pem
chmod 400 ${cfg.configDir}/cert.pem
install -Dm400 -o ${cfg.user} -g ${cfg.group} ${toString cfg.declarative.cert} ${cfg.configDir}/cert.pem
''}
${optionalString (cfg.declarative.key != null) ''
cp ${toString cfg.declarative.key} ${cfg.configDir}/key.pem
chown ${cfg.user}:${cfg.group} ${cfg.configDir}/key.pem
chmod 400 ${cfg.configDir}/key.pem
install -Dm400 -o ${cfg.user} -g ${cfg.group} ${toString cfg.declarative.key} ${cfg.configDir}/key.pem
''}
''}"
;
11 changes: 5 additions & 6 deletions nixos/modules/services/web-servers/apache-httpd/default.nix
Original file line number Diff line number Diff line change
@@ -21,10 +21,9 @@ let
else [{ip = "*"; port = 80;}];

getListen = cfg:
let list = (lib.optional (cfg.port != 0) {ip = "*"; port = cfg.port;}) ++ cfg.listen;
in if list == []
then defaultListen cfg
else list;
if cfg.listen == []
then defaultListen cfg
else cfg.listen;

listenToString = l: "${l.ip}:${toString l.port}";

@@ -638,7 +637,7 @@ in
message = "SSL is enabled for httpd, but sslServerCert and/or sslServerKey haven't been specified."; }
];

warnings = map (cfg: ''apache-httpd's port option is deprecated. Use listen = [{/*ip = "*"; */ port = ${toString cfg.port};}]; instead'' ) (lib.filter (cfg: cfg.port != 0) allHosts);
warnings = map (cfg: "apache-httpd's extraSubservices option is deprecated. Most existing subservices have been ported to the NixOS module system. Please update your configuration accordingly.") (lib.filter (cfg: cfg.extraSubservices != []) allHosts);

users.users = optionalAttrs (mainCfg.user == "wwwrun") (singleton
{ name = "wwwrun";
@@ -672,7 +671,7 @@ in

wantedBy = [ "multi-user.target" ];
wants = [ "keys.target" ];
after = [ "network.target" "fs.target" "postgresql.service" "keys.target" ];
after = [ "network.target" "fs.target" "keys.target" ];

path =
[ httpd pkgs.coreutils pkgs.gnugrep ]
Original file line number Diff line number Diff line change
@@ -24,14 +24,6 @@ with lib;
'';
};

port = mkOption {
type = types.int;
default = 0;
description = ''
Port for the server. Option will be removed, use <option>listen</option> instead.
'';
};

listen = mkOption {
type = types.listOf (types.submodule (
{