about summary refs log tree commit diff
path: root/hosts/luna/default.nix
blob: b2cf07bb9ef1e366ad1d1c7c9e6a24ac7134603e (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
{ config, pkgs, lib, secrets, hostname, inputs, user, ... }: {

  imports = [
    "${inputs.impermanence}/nixos.nix"

    ./hardware.nix

    ../../modules/power-save
    ../../modules/bluetooth
  ];

  services = {
    # Configure keymap in X11
    xserver.layout = "gb";
    logind.extraConfig = ''
      # don’t shutdown when power button is short-pressed
      HandlePowerKey=ignore
    '';
  };

  # Pick only one of the below networking options.
  networking = {
    wireless = {
      enable = true; # Enables wireless support via wpa_supplicant.
      networks = secrets.wifi_networks;
    };
    # networkmanager.enable = true;  # Easiest to use and most distros use this by default.
    # Configure network proxy if necessary
    # proxy.default = "http://user:password@proxy:port/";
    # proxy.noProxy = "127.0.0.1,localhost,internal.domain";
  };

  environment.systemPackages = with pkgs; [
    dmidecode #needed for updating coreboot bios
    xf86_input_cmt #chromebook touchpad drivers
  ];

  environment.persistence."/persist" = {
    directories = [
      "/var/log"
      "/var/lib"
    ];
    files = [
      "/etc/machine-id"
      "/etc/nix/id_rsa"
    ];
  };

  environment.etc."nix-index/files".source = inputs.nix-index.legacyPackages.x86_64-linux.database;

}