summaryrefslogtreecommitdiffstats
path: root/makefu/2configs
diff options
context:
space:
mode:
authorlassulus <lass@aidsballs.de>2015-08-23 16:53:38 +0200
committerlassulus <lass@aidsballs.de>2015-08-23 16:53:38 +0200
commit65a2d75b140e7eca79a8084ef331b1d4db8f07f5 (patch)
tree0d1cd09fe24c1eacaf550859a44ab1fa1d686e0e /makefu/2configs
parent8247a5a618d6b0fc3688077fe36508b8bf88dcc3 (diff)
parentdce1ad91445297ecc122f968a12339438eabaa63 (diff)
Merge branch 'makefu'
Diffstat (limited to 'makefu/2configs')
-rw-r--r--makefu/2configs/base-gui.nix30
-rw-r--r--makefu/2configs/cgit-retiolum.nix2
-rw-r--r--makefu/2configs/exim-retiolum.nix11
-rw-r--r--makefu/2configs/main-laptop.nix23
-rw-r--r--makefu/2configs/sda-crypto-root-home.nix39
-rw-r--r--makefu/2configs/tp-x200.nix27
-rw-r--r--makefu/2configs/tp-x220.nix16
-rw-r--r--makefu/2configs/tp-x2x0.nix27
-rw-r--r--makefu/2configs/urlwatch.nix17
-rw-r--r--makefu/2configs/wwan.nix27
-rw-r--r--makefu/2configs/zsh-user.nix10
11 files changed, 185 insertions, 44 deletions
diff --git a/makefu/2configs/base-gui.nix b/makefu/2configs/base-gui.nix
index 55fcd6baa..6896a66dc 100644
--- a/makefu/2configs/base-gui.nix
+++ b/makefu/2configs/base-gui.nix
@@ -1,11 +1,15 @@
{ config, lib, pkgs, ... }:
##
-# of course this name is a lie - it prepares a GUI environment close to my
-# current configuration.
+# of course this name is a lie
+# - it prepares a GUI environment close to my
+# current configuration,specifically:
#
-# autologin with mainUser into awesome
-##
+# * autologin with mainUser into awesome
+# * audio
+# * terminus font
#
+# if this is not enough, check out main-laptop.nix
+
with lib;
let
mainUser = config.krebs.build.user.name;
@@ -28,14 +32,6 @@ in
displayManager.auto.user = mainUser;
desktopManager.xterm.enable = false;
};
- services.redshift = {
- enable = true;
- latitude = "48.7";
- longitude = "9.1";
- };
-
-## FONTS
-# TODO: somewhere else?
i18n.consoleFont = "Lat2-Terminus16";
@@ -49,14 +45,12 @@ in
environment.systemPackages = with pkgs;[
xlockmore
rxvt_unicode-with-plugins
- vlc
firefox
- chromium
];
- # TODO: use mainUser
- users.extraUsers.makefu.extraGroups = [ "audio" ];
+ users.extraUsers.${mainUser}.extraGroups = [ "audio" ];
+
hardware.pulseaudio = {
- enable = true;
- # systemWide = true;
+ enable = true;
+ # systemWide = true;
};
}
diff --git a/makefu/2configs/cgit-retiolum.nix b/makefu/2configs/cgit-retiolum.nix
index d352f5792..8d9439569 100644
--- a/makefu/2configs/cgit-retiolum.nix
+++ b/makefu/2configs/cgit-retiolum.nix
@@ -8,7 +8,7 @@ let
krebs-repos = mapAttrs make-krebs-repo {
stockholm = {
- desc = "take all the computers hostage, they'll love you!";
+ desc = "Make all the systems into 1systems!";
};
};
diff --git a/makefu/2configs/exim-retiolum.nix b/makefu/2configs/exim-retiolum.nix
new file mode 100644
index 000000000..fc570ba97
--- /dev/null
+++ b/makefu/2configs/exim-retiolum.nix
@@ -0,0 +1,11 @@
+{ config, lib, pkgs, ... }:
+
+with lib;
+{
+ krebs.exim-retiolum.enable = true;
+ environment.systemPackages = with pkgs; [
+ msmtp
+ mutt-kz
+ ];
+
+}
diff --git a/makefu/2configs/main-laptop.nix b/makefu/2configs/main-laptop.nix
new file mode 100644
index 000000000..8d2c8213e
--- /dev/null
+++ b/makefu/2configs/main-laptop.nix
@@ -0,0 +1,23 @@
+{ config, lib, pkgs, ... }:
+
+# stuff for the main laptop
+# this is pretty much nice-to-have and does
+# not fit into base-gui
+
+with lib;
+{
+ imports = [ ./base-gui.nix ];
+ environment.systemPackages = with pkgs;[
+ vlc
+ firefox
+ chromium
+ keepassx
+ ];
+
+ services.redshift = {
+ enable = true;
+ latitude = "48.7";
+ longitude = "9.1";
+ };
+
+}
diff --git a/makefu/2configs/sda-crypto-root-home.nix b/makefu/2configs/sda-crypto-root-home.nix
new file mode 100644
index 000000000..3821c7504
--- /dev/null
+++ b/makefu/2configs/sda-crypto-root-home.nix
@@ -0,0 +1,39 @@
+{ config, lib, pkgs, ... }:
+
+# ssd #
+# sda: bootloader grub2
+# sda1: boot ext4 (label nixboot)
+# sda2: cryptoluks -> lvm:
+# / (main-root)
+# /home (main-home)
+
+with lib;
+{
+ boot = {
+ loader.grub.enable =true;
+ loader.grub.version =2;
+ loader.grub.device = "/dev/sda";
+
+ initrd.luks.devices = [ { name = "main"; device = "/dev/sda2"; allowDiscards=true; }];
+ initrd.luks.cryptoModules = ["aes" "sha512" "sha1" "xts" ];
+ initrd.availableKernelModules = ["xhci_hcd" "ehci_pci" "ahci" "usb_storage" ];
+ };
+ fileSystems = {
+ "/" = {
+ device = "/dev/mapper/main-root";
+ fsType = "ext4";
+ options="defaults,discard";
+ };
+ # TODO: just import sda-crypto-root, add this device
+ "/home" = {
+ device = "/dev/mapper/main-home";
+ fsType = "ext4";
+ options="defaults,discard";
+ };
+ "/boot" = {
+ device = "/dev/disk/by-label/nixboot";
+ fsType = "ext4";
+ options="defaults,discard";
+ };
+ };
+}
diff --git a/makefu/2configs/tp-x200.nix b/makefu/2configs/tp-x200.nix
index 2bbc75c20..aed6d6448 100644
--- a/makefu/2configs/tp-x200.nix
+++ b/makefu/2configs/tp-x200.nix
@@ -2,36 +2,13 @@
with lib;
{
- #services.xserver = {
- # videoDriver = "intel";
- #};
+
+ imports = [ ./tp-x2x0.nix ];
boot = {
kernelModules = [ "tp_smapi" "msr" ];
extraModulePackages = [ config.boot.kernelPackages.tp_smapi ];
};
-
- #networking.wireless.enable = true;
-
- hardware.enableAllFirmware = true;
- nixpkgs.config.allowUnfree = true;
-
- zramSwap.enable = true;
- zramSwap.numDevices = 2;
-
- hardware.trackpoint.enable = true;
- hardware.trackpoint.sensitivity = 255;
- hardware.trackpoint.speed = 255;
- services.xserver.displayManager.sessionCommands = ''
- xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation" 1
- xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Button" 2
- xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Timeout" 200
- '';
-
services.thinkfan.enable = true;
- services.tlp.enable = true;
- services.tlp.extraConfig = ''
- START_CHARGE_THRESH_BAT0=80
- '';
}
diff --git a/makefu/2configs/tp-x220.nix b/makefu/2configs/tp-x220.nix
new file mode 100644
index 000000000..d079d5b37
--- /dev/null
+++ b/makefu/2configs/tp-x220.nix
@@ -0,0 +1,16 @@
+{ config, lib, pkgs, ... }:
+
+with lib;
+{
+
+ imports = [ ./tp-x2x0.nix ];
+
+ boot.kernelModules = [ "kvm-intel" ];
+ services.xserver.displayManager.sessionCommands =''
+ xinput set-int-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation" 8 1
+ xinput set-int-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Button" 8 2
+ xinput set-int-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Timeout" 8 200
+ xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Axes" 6 7 4 5
+ '';
+
+}
diff --git a/makefu/2configs/tp-x2x0.nix b/makefu/2configs/tp-x2x0.nix
new file mode 100644
index 000000000..e65563014
--- /dev/null
+++ b/makefu/2configs/tp-x2x0.nix
@@ -0,0 +1,27 @@
+{ config, lib, pkgs, ... }:
+
+with lib;
+{
+ # TODO: pot this somewhere else
+ networking.wireless.enable = true;
+
+ hardware.enableAllFirmware = true;
+ nixpkgs.config.allowUnfree = true;
+
+ zramSwap.enable = true;
+ zramSwap.numDevices = 2;
+
+ hardware.trackpoint.enable = true;
+ hardware.trackpoint.sensitivity = 220;
+ hardware.trackpoint.speed = 220;
+ services.xserver.displayManager.sessionCommands = ''
+ xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation" 1
+ xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Button" 2
+ xinput set-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Timeout" 200
+ '';
+
+ services.tlp.enable = true;
+ services.tlp.extraConfig = ''
+ START_CHARGE_THRESH_BAT0=80
+ '';
+}
diff --git a/makefu/2configs/urlwatch.nix b/makefu/2configs/urlwatch.nix
new file mode 100644
index 000000000..933cb93c5
--- /dev/null
+++ b/makefu/2configs/urlwatch.nix
@@ -0,0 +1,17 @@
+{ config, ... }:
+
+{
+ krebs.urlwatch = {
+ enable = true;
+ mailto = config.krebs.users.makefu.mail;
+ onCalendar = "*-*-* 05:00:00";
+ urls = [
+ ## nixpkgs maintenance
+ https://api.github.com/repos/ovh/python-ovh/tags
+ https://api.github.com/repos/embray/d2to1/tags
+ http://git.sysphere.org/vicious/log/?qt=grep&q=Next+release
+
+ ];
+ };
+}
+
diff --git a/makefu/2configs/wwan.nix b/makefu/2configs/wwan.nix
new file mode 100644
index 000000000..1492213bb
--- /dev/null
+++ b/makefu/2configs/wwan.nix
@@ -0,0 +1,27 @@
+{ config, lib, pkgs, ... }:
+
+let
+ mainUser = config.krebs.build.user;
+in {
+ environment.systemPackages = with pkgs;[
+ wvdial
+ ];
+
+ # configure for NETZCLUB
+ environment.wvdial.dialerDefaults = ''
+ Phone = *99***1#
+ Dial Command = ATDT
+ Modem = /dev/ttyACM0
+ Baud = 460800
+ Init1 = AT+CGDCONT=1,"IP","pinternet.interkom.de","",0,0
+ Init2 = ATZ
+ Init3 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
+ ISDN = 0
+ Modem Type = Analog Modem
+ Username = netzclub
+ Password = netzclub
+ Stupid Mode = 1
+ Idle Seconds = 0'';
+
+ users.extraUsers.${mainUser.name}.extraGroups = [ "dialout" ];
+}
diff --git a/makefu/2configs/zsh-user.nix b/makefu/2configs/zsh-user.nix
new file mode 100644
index 000000000..3089b706a
--- /dev/null
+++ b/makefu/2configs/zsh-user.nix
@@ -0,0 +1,10 @@
+{ config, lib, pkgs, ... }:
+##
+with lib;
+let
+ mainUser = config.krebs.build.user.name;
+in
+{
+ programs.zsh.enable = true;
+ users.extraUsers.${mainUser}.shell = "/run/current-system/sw/bin/zsh";
+}