summaryrefslogtreecommitdiff
path: root/machines/dragon.nix
blob: f3257bf384572f9c7c81f2ccb23b1485969d83dc (plain)
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
{ config, lib, pkgs, ... }:
{
  imports =
    [ ../config/common.nix
      ../config/users.nix
    ];

  boot.kernelParams = [ "console=tty0" ''console="ttyS0,115200n8"'' ];
  boot.loader.grub.extraConfig = ''
    GRUB_TERMINAL="console serial"
    GRUB_SERIAL_COMMAND="serial --speed=115200 --unit=0 --word=8 --parity=no --stop=1"
  '';
  boot.loader.grub.enable = true;
  boot.loader.grub.version = 2;
  boot.loader.grub.devices = ["/dev/sda" "/dev/sdb"];
  
  networking = {
    hostName = lib.mkForce "dragon";
  };

  services = {
    openssh = {
      enable = lib.mkDefault true;
      passwordAuthentication = false;
    };
  };

  fileSystems = {
    "/storage" = {
      device = "/dev/sda3";
      fsType = "btrfs";
      options = [ "subvol=storage" ];
    };
  };

  system.stateVersion = lib.mkForce "17.09";
}