Skip to content
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
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: caaaaa7fbb58
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 3873f43fc39d
Choose a head ref
  • 2 commits
  • 2 files changed
  • 1 contributor

Commits on Dec 5, 2018

  1. Unverified

    This commit is not signed, but one or more authors requires that any commit attributed to them is signed.
    Copy the full SHA
    199b4c4 View commit details
  2. prometheus/exporters: fix regression in DynamicUser behavior

    Instead of setting User/Group only when DynamicUser is disabled, the
    previous version of the code set it only when it was enabled. This
    caused services with DynamicUser enabled to actually run as nobody, and
    services without DynamicUser enabled to run as root.
    
    Regression from fbb7e0c.
    delroth authored and globin committed Dec 5, 2018

    Unverified

    This commit is not signed, but one or more authors requires that any commit attributed to them is signed.
    Copy the full SHA
    3873f43 View commit details
Showing with 6 additions and 1 deletion.
  1. +1 −1 nixos/modules/services/monitoring/prometheus/exporters.nix
  2. +5 −0 nixos/modules/services/monitoring/prometheus/exporters/tor.nix
2 changes: 1 addition & 1 deletion nixos/modules/services/monitoring/prometheus/exporters.nix
Original file line number Diff line number Diff line change
@@ -127,7 +127,7 @@ let
serviceConfig.Restart = mkDefault "always";
serviceConfig.PrivateTmp = mkDefault true;
serviceConfig.WorkingDirectory = mkDefault /tmp;
} serviceOpts ] ++ optional (serviceOpts.serviceConfig.DynamicUser or false) {
} serviceOpts ] ++ optional (!(serviceOpts.serviceConfig.DynamicUser or false)) {
serviceConfig.User = conf.user;
serviceConfig.Group = conf.group;
});
Original file line number Diff line number Diff line change
@@ -36,5 +36,10 @@ in
${concatStringsSep " \\\n " cfg.extraFlags}
'';
};

# CPython requires a process to either have $HOME defined or run as a UID
# defined in /etc/passwd. The latter is false with DynamicUser, so define a
# dummy $HOME. https://bugs.python.org/issue10496
environment = { HOME = "/var/empty"; };
};
}