summary refs log tree commit diff stats
path: root/modules/services
diff options
context:
space:
mode:
authorAlan Pearce2017-09-23 13:59:19 +0200
committerAlan Pearce2017-09-23 14:10:26 +0200
commit0f2c55992677e78d5d2908d0648e410ef9b27436 (patch)
treeb2a3432e15dd9af506c317af608ea69721979a41 /modules/services
parent496b4ed379afe7f1e0563243a0a5efe0857fe3bb (diff)
downloadnixos-configuration-0f2c55992677e78d5d2908d0648e410ef9b27436.tar.lz
nixos-configuration-0f2c55992677e78d5d2908d0648e410ef9b27436.tar.zst
nixos-configuration-0f2c55992677e78d5d2908d0648e410ef9b27436.zip
Organise modules into folders
Diffstat (limited to 'modules/services')
-rw-r--r--modules/services/syncthing.nix12
-rw-r--r--modules/services/xserver.nix88
-rw-r--r--modules/services/zeroconf.nix7
3 files changed, 107 insertions, 0 deletions
diff --git a/modules/services/syncthing.nix b/modules/services/syncthing.nix
new file mode 100644
index 0000000..5a3e1d6
--- /dev/null
+++ b/modules/services/syncthing.nix
@@ -0,0 +1,12 @@
+{ config, pkgs, ... }:
+
+{ services.syncthing = {
+    enable = true;
+    user = "alan";
+    group = "users";
+    openDefaultPorts = true;
+    systemService = true;
+    useInotify = true;
+    dataDir = "/home/alan/.config/syncthing";
+  };
+}
diff --git a/modules/services/xserver.nix b/modules/services/xserver.nix
new file mode 100644
index 0000000..2cef678
--- /dev/null
+++ b/modules/services/xserver.nix
@@ -0,0 +1,88 @@
+{ config, pkgs, ... }:
+
+{ services.xserver = {
+    enable = true;
+    enableCtrlAltBackspace = true;
+    exportConfiguration = true;
+  };
+
+  services.dbus.socketActivated = true;
+
+  environment.sessionVariables = {
+    XCURSOR_PATH = [
+      "${config.system.path}/share/icons"
+      "$HOME/.icons"
+      "$HOME/.nix-profile/share/icons/"
+    ];
+  };
+
+  environment.systemPackages = with pkgs; [
+    xorg.xmodmap
+    xorg.xinit
+    xorg.xev
+    xorg.xdpyinfo
+    xclip
+    xfontsel
+
+    vanilla-dmz
+
+    hicolor_icon_theme
+    adapta-gtk-theme
+    flat-plat
+    paper-gtk-theme
+    paper-icon-theme
+
+    arc-icon-theme
+    tango-icon-theme
+
+    gtk-engine-murrine
+    gtk_engines
+  ];
+
+  fonts = {
+    enableFontDir = true;
+    enableDefaultFonts = true;
+    fontconfig = {
+      defaultFonts = {
+        monospace = [ "Liberation Mono" ];
+        sansSerif = [ "Liberation Sans" ];
+        serif = [ "Liberation Serif" ];
+      };
+      ultimate = {
+        enable = true;
+        # presets:
+        # ultimate1 ultimate2 ultimate3 ultimate4 ultimate5 osx windowsxp
+        preset = "ultimate3";
+      };
+    };
+    fonts = with pkgs; [
+      cantarell_fonts
+      carlito
+      dejavu_fonts
+      fantasque-sans-mono
+      fira
+      fira-code
+      fira-mono
+      font-droid
+      font-awesome-ttf
+      hack-font
+      liberation_ttf
+      mononoki
+      (nerdfonts.override {
+        withFont = "Monoid";
+      })
+      opensans-ttf
+      paratype-pt-mono
+      paratype-pt-sans
+      paratype-pt-serif
+      roboto
+      roboto-mono
+      roboto-slab
+      source-code-pro
+      source-sans-pro
+      source-serif-pro
+      terminus_font
+      xorg.fontxfree86type1
+    ];
+  };
+}
diff --git a/modules/services/zeroconf.nix b/modules/services/zeroconf.nix
new file mode 100644
index 0000000..aa4b47e
--- /dev/null
+++ b/modules/services/zeroconf.nix
@@ -0,0 +1,7 @@
+{ config, pkgs, ... }:
+
+{ services.avahi = {
+    enable = true;
+    nssmdns = true;
+  };
+}