mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 14:54:29 +01:00
Merge pull request #58458 from worldofpeace/colord/no-root
nixos/colord: don't run as root
This commit is contained in:
commit
81e2fb5303
2 changed files with 11 additions and 9 deletions
|
@ -18,22 +18,23 @@ in {
|
|||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
environment.systemPackages = [ pkgs.colord ];
|
||||
|
||||
services.dbus.packages = [ pkgs.colord ];
|
||||
|
||||
services.udev.packages = [ pkgs.colord ];
|
||||
|
||||
environment.systemPackages = [ pkgs.colord ];
|
||||
systemd.packages = [ pkgs.colord ];
|
||||
|
||||
systemd.services.colord = {
|
||||
description = "Manage, Install and Generate Color Profiles";
|
||||
serviceConfig = {
|
||||
Type = "dbus";
|
||||
BusName = "org.freedesktop.ColorManager";
|
||||
ExecStart = "${pkgs.colord}/libexec/colord";
|
||||
PrivateTmp = true;
|
||||
};
|
||||
environment.etc."tmpfiles.d/colord.conf".source = "${pkgs.colord}/lib/tmpfiles.d/colord.conf";
|
||||
|
||||
users.users.colord = {
|
||||
home = "/var/lib/colord";
|
||||
group = "colord";
|
||||
};
|
||||
|
||||
users.groups.colord = {};
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
@ -56,6 +56,7 @@ stdenv.mkDerivation rec {
|
|||
"-Dlibcolordcompat=true"
|
||||
"-Dsane=true"
|
||||
"-Dvapi=true"
|
||||
"-Ddaemon_user=colord"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
|
|
Loading…
Reference in a new issue