about summary refs log tree commit diff
path: root/labernix/machines/labtop.nix
blob: bf376ba589b2b568076216af46db135b44f8ab53 (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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
{ pkgs, ... }:

let
  greybird = pkgs.stdenv.mkDerivation {
    name = "greybird-xfce-theme";

    src = pkgs.fetchFromGitHub {
      repo = "Greybird";
      owner = "shimmerproject";
      rev = "61ec18d22780aa87998381599c941e0cf4f7bfb5";
      sha256 = "03h8hba4lfp337a4drylcplrbggry9gz8dq1f3gjy25fhqkgvq05";
    };

    phases = [ "unpackPhase" "installPhase" ];

    installPhase = ''
      mkdir -p "$out/share/themes/Greybird" \
               "$out/share/themes/Greybird-compact/xfwm4"
      cp -vrt "$out/share/themes/Greybird" \
        gtk-* metacity-1 unity xfce-notify-4.0 xfwm4
      cp -vrt "$out/share/themes/Greybird-compact/xfwm4" \
        xfwm4_compact/*
    '';
  };

in {
  imports = [ ../common.nix ];

  i18n = {
    consoleFont = "lat9w-16";
    consoleKeyMap = "us";
    defaultLocale = "de_DE.UTF-8";
  };

  # TODO: This is a dummy, replace it once we know about the real root fs.
  fileSystems."/".label = "root";
  boot.loader.grub.device = "nodev";

  environment.systemPackages = [
    greybird
    #repetierhost <- TODO
    pkgs.firefox
    pkgs.gimp
    pkgs.freecad
    pkgs.openscad
    #pkgs.pronterface <- TODO
    pkgs.blender
    pkgs.slic3r
    pkgs.libreoffice
    pkgs.inkscape
    pkgs.filezilla
    pkgs.gmpc
    pkgs.vlc
  ];

  # TODO: Needed for slic3r right now.
  nixpkgs.config.allowBroken = true;

  services.xserver.enable = true;
  services.xserver.layout = "us";
  services.xserver.xkbOptions = "eurosign:e";

  services.xserver.displayManager.auto.enable = true;
  services.xserver.displayManager.auto.user = "openlab";
  services.xserver.desktopManager.xfce.enable = true;

  users.mutableUsers = false;
  users.extraUsers.openlab = {
    uid = 1000;
    isNormalUser = true;
  };
}