diff options
author | Frederik Rietdijk <freddyrietdijk@fridh.nl> | 2018-09-23 09:31:28 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-09-23 09:31:28 +0200 |
commit | 56853dc6d83a861050bbc02041dbe65f7b1b6f63 (patch) | |
tree | 70fdf276f8d889018a3ec9fc573e01fa961d289c /nixos/modules | |
parent | 343ac4d2fc6029ef6a2451d31890903f6afe79f2 (diff) | |
parent | 92158a4b2cda39ab3990682aa23644462e1a5860 (diff) | |
download | nixlib-56853dc6d83a861050bbc02041dbe65f7b1b6f63.tar nixlib-56853dc6d83a861050bbc02041dbe65f7b1b6f63.tar.gz nixlib-56853dc6d83a861050bbc02041dbe65f7b1b6f63.tar.bz2 nixlib-56853dc6d83a861050bbc02041dbe65f7b1b6f63.tar.lz nixlib-56853dc6d83a861050bbc02041dbe65f7b1b6f63.tar.xz nixlib-56853dc6d83a861050bbc02041dbe65f7b1b6f63.tar.zst nixlib-56853dc6d83a861050bbc02041dbe65f7b1b6f63.zip |
Merge pull request #45941 from NixOS/staging-next
Staging next
Diffstat (limited to 'nixos/modules')
-rw-r--r-- | nixos/modules/config/iproute2.nix | 35 | ||||
-rw-r--r-- | nixos/modules/config/system-path.nix | 2 | ||||
-rw-r--r-- | nixos/modules/services/x11/hardware/libinput.nix | 2 |
3 files changed, 24 insertions, 15 deletions
diff --git a/nixos/modules/config/iproute2.nix b/nixos/modules/config/iproute2.nix index 881ad671a627..a1d9ebcec66b 100644 --- a/nixos/modules/config/iproute2.nix +++ b/nixos/modules/config/iproute2.nix @@ -4,20 +4,29 @@ with lib; let cfg = config.networking.iproute2; - confDir = "/run/iproute2"; in { - options.networking.iproute2.enable = mkEnableOption "copy IP route configuration files"; - - config = mkMerge [ - ({ nixpkgs.config.iproute2.confDir = confDir; }) - - (mkIf cfg.enable { - system.activationScripts.iproute2 = '' - cp -R ${pkgs.iproute}/etc/iproute2 ${confDir} - chmod -R 664 ${confDir} - chmod +x ${confDir} + options.networking.iproute2 = { + enable = mkEnableOption "copy IP route configuration files"; + rttablesExtraConfig = mkOption { + type = types.lines; + default = ""; + description = '' + Verbatim lines to add to /etc/iproute2/rt_tables ''; - }) - ]; + }; + }; + + config = mkIf cfg.enable { + environment.etc."iproute2/bpf_pinning" = { mode = "0644"; text = fileContents "${pkgs.iproute}/etc/iproute2/bpf_pinning"; }; + environment.etc."iproute2/ematch_map" = { mode = "0644"; text = fileContents "${pkgs.iproute}/etc/iproute2/ematch_map"; }; + environment.etc."iproute2/group" = { mode = "0644"; text = fileContents "${pkgs.iproute}/etc/iproute2/group"; }; + environment.etc."iproute2/nl_protos" = { mode = "0644"; text = fileContents "${pkgs.iproute}/etc/iproute2/nl_protos"; }; + environment.etc."iproute2/rt_dsfield" = { mode = "0644"; text = fileContents "${pkgs.iproute}/etc/iproute2/rt_dsfield"; }; + environment.etc."iproute2/rt_protos" = { mode = "0644"; text = fileContents "${pkgs.iproute}/etc/iproute2/rt_protos"; }; + environment.etc."iproute2/rt_realms" = { mode = "0644"; text = fileContents "${pkgs.iproute}/etc/iproute2/rt_realms"; }; + environment.etc."iproute2/rt_scopes" = { mode = "0644"; text = fileContents "${pkgs.iproute}/etc/iproute2/rt_scopes"; }; + environment.etc."iproute2/rt_tables" = { mode = "0644"; text = (fileContents "${pkgs.iproute}/etc/iproute2/rt_tables") + + (optionalString (cfg.rttablesExtraConfig != "") "\n\n${cfg.rttablesExtraConfig}"); }; + }; } diff --git a/nixos/modules/config/system-path.nix b/nixos/modules/config/system-path.nix index ffb437491f6c..3c24dab85e4d 100644 --- a/nixos/modules/config/system-path.nix +++ b/nixos/modules/config/system-path.nix @@ -13,7 +13,7 @@ let pkgs.attr pkgs.bashInteractive # bash with ncurses support pkgs.bzip2 - pkgs.coreutils + pkgs.coreutils-full pkgs.cpio pkgs.curl pkgs.diffutils diff --git a/nixos/modules/services/x11/hardware/libinput.nix b/nixos/modules/services/x11/hardware/libinput.nix index 072004d5dd91..58fe702d4969 100644 --- a/nixos/modules/services/x11/hardware/libinput.nix +++ b/nixos/modules/services/x11/hardware/libinput.nix @@ -205,7 +205,7 @@ in { }) ]; - services.udev.packages = [ pkgs.libinput ]; + services.udev.packages = [ pkgs.libinput.out ]; services.xserver.config = '' |