dotfiles/nixos/common-hardware.nix

62 lines
1.5 KiB
Nix
Raw Normal View History

2019-07-18 22:17:36 +01:00
{ config, pkgs, lib, ... }:
{
2020-03-20 13:09:39 +00:00
boot.kernelModules = [ "fuse" ];
services.smartd.enable = true;
2019-07-18 22:17:36 +01:00
sound.enable = true;
2020-03-20 13:09:39 +00:00
2019-07-18 22:17:36 +01:00
networking.networkmanager.enable = true;
2020-03-20 13:09:39 +00:00
2020-07-23 21:02:57 +01:00
hardware.enableAllFirmware = true;
2019-07-18 22:17:36 +01:00
hardware.enableRedistributableFirmware = true;
hardware.cpu.intel.updateMicrocode = true;
hardware.pulseaudio = {
enable = true;
package = pkgs.pulseaudioFull;
2019-08-08 21:23:29 +01:00
support32Bit = true;
2019-07-18 22:17:36 +01:00
extraModules = [ pkgs.pulseaudio-modules-bt ];
2020-05-10 08:45:21 +01:00
daemon.config = {
nice-level= -15;
realtime-scheduling = "yes";
};
2019-07-18 22:17:36 +01:00
};
2020-04-26 14:08:40 +01:00
2019-07-18 22:17:36 +01:00
hardware.bluetooth = {
enable = true;
package = pkgs.bluezFull;
2020-05-09 11:02:36 +01:00
config = {
General = { Enable = "Source,Sink,Media,Socket"; };
};
2019-07-18 22:17:36 +01:00
};
2020-06-13 08:57:23 +01:00
services.blueman.enable = true;
2020-04-26 13:23:27 +01:00
services.printing = {
enable = true;
2020-04-26 14:08:40 +01:00
drivers = with pkgs; [ epson-escpr samsung-unified-linux-driver splix ];
2020-04-26 13:23:27 +01:00
};
hardware.printers.ensurePrinters = [{
2020-12-22 14:35:08 +00:00
description = "Epson XP-540 via brix";
name = "epson_xp540_via_brix";
2020-12-22 16:24:12 +00:00
deviceUri = "ipp://brix.local:631/printers/epson_xp540";
2020-04-26 13:23:27 +01:00
model = "epson-inkjet-printer-escpr/Epson-XP-540_Series-epson-escpr-en.ppd";
ppdOptions = { PageSize = "A4"; Duplex = "DuplexNoTumble"; };
}];
2020-04-26 14:08:40 +01:00
hardware.sane = {
enable = true;
2020-12-22 21:04:22 +00:00
netConf = ''
10.0.0.232
brix.local
brix.vpn
'';
snapshot = true;
extraBackends = with pkgs; [ sane-airscan utsushi ];
2020-04-26 14:08:40 +01:00
};
2019-10-07 18:33:11 +01:00
powerManagement.enable = (lib.mkForce true);
2019-07-18 22:17:36 +01:00
powerManagement.cpuFreqGovernor = (lib.mkForce null);
powerManagement.powertop.enable = true;
2019-07-18 22:17:36 +01:00
}