From 29746aec06b7d42d3c87245f6f14f048234251e4 Mon Sep 17 00:00:00 2001 From: tv Date: Sat, 6 Feb 2016 18:54:01 +0100 Subject: krebs.{backup.plans,hosts,users}.*.name: add default value --- tv/2configs/backup.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tv/2configs') diff --git a/tv/2configs/backup.nix b/tv/2configs/backup.nix index ce937a744..f4d368557 100644 --- a/tv/2configs/backup.nix +++ b/tv/2configs/backup.nix @@ -1,7 +1,7 @@ { config, lib, ... }: with lib; { - krebs.backup.plans = addNames { + krebs.backup.plans = { wu-home-xu = { method = "push"; src = { host = config.krebs.hosts.wu; path = "/home"; }; -- cgit v1.2.3 From 02c1f8d2703aa03e41adcd5aec0d3ec402bbb367 Mon Sep 17 00:00:00 2001 From: tv Date: Sun, 7 Feb 2016 03:09:14 +0100 Subject: tv: accept internet echo requests --- tv/2configs/default.nix | 1 + 1 file changed, 1 insertion(+) (limited to 'tv/2configs') diff --git a/tv/2configs/default.nix b/tv/2configs/default.nix index 57c4620c4..52d85f856 100644 --- a/tv/2configs/default.nix +++ b/tv/2configs/default.nix @@ -165,6 +165,7 @@ with lib; { tv.iptables.enable = true; + tv.iptables.accept-echo-request = "internet"; } { -- cgit v1.2.3 From 949f466cf78ba2e76002012715172e5d5d394006 Mon Sep 17 00:00:00 2001 From: tv Date: Sun, 7 Feb 2016 05:17:07 +0100 Subject: tv: s/_/-/g in usernames --- tv/2configs/git.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tv/2configs') diff --git a/tv/2configs/git.nix b/tv/2configs/git.nix index b8180085f..85fd72539 100644 --- a/tv/2configs/git.nix +++ b/tv/2configs/git.nix @@ -90,7 +90,7 @@ let with git // config.krebs.users; repo: singleton { - user = [ tv tv_xu ]; + user = [ tv tv-xu ]; repo = [ repo ]; perm = push "refs/*" [ non-fast-forward create delete merge ]; } ++ -- cgit v1.2.3 From b819d6c452605af66282c14e25907793a4b77c65 Mon Sep 17 00:00:00 2001 From: tv Date: Sun, 7 Feb 2016 07:47:29 +0100 Subject: tv vim: add file-line plugin --- tv/2configs/vim.nix | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) (limited to 'tv/2configs') diff --git a/tv/2configs/vim.nix b/tv/2configs/vim.nix index 23f90af05..9f702cd4d 100644 --- a/tv/2configs/vim.nix +++ b/tv/2configs/vim.nix @@ -13,9 +13,21 @@ let environment.variables.VIMINIT = ":so /etc/vimrc"; }; - extra-runtimepath = concatStringsSep "," [ - "${pkgs.vimPlugins.undotree}/share/vim-plugins/undotree" - ]; + extra-runtimepath = let + inherit (pkgs.vimUtils) buildVimPlugin rtpPath; + fromVimPlugins = pkgs: concatStringsSep "," + (mapAttrsToList (name: pkg: "${pkg}/${rtpPath}/${name}") pkgs); + in fromVimPlugins { + inherit (pkgs.vimPlugins) undotree; + file-line = buildVimPlugin { + name = "file-line-1.0"; + src = pkgs.fetchgit { + url = git://github.com/bogado/file-line; + rev = "refs/tags/1.0"; + sha256 = "0z47zq9rqh06ny0q8lpcdsraf3lyzn9xvb59nywnarf3nxrk6hx0"; + }; + }; + }; dirs = { backupdir = "$HOME/.cache/vim/backup"; -- cgit v1.2.3 From 698296eb8c986127e0fb195a51b3adf3f31eeedf Mon Sep 17 00:00:00 2001 From: tv Date: Sun, 7 Feb 2016 07:50:17 +0100 Subject: tv vim: restore original umask --- tv/2configs/vim.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tv/2configs') diff --git a/tv/2configs/vim.nix b/tv/2configs/vim.nix index 9f702cd4d..8a6299a39 100644 --- a/tv/2configs/vim.nix +++ b/tv/2configs/vim.nix @@ -47,9 +47,10 @@ let vim = pkgs.writeScriptBin "vim" '' #! ${pkgs.dash}/bin/dash set -f + umask=$(umask) umask 0077 ${concatStringsSep "\n" (map (x: "mkdir -p ${x}") mkdirs)} - umask 0022 + umask "$umask" exec ${pkgs.vim}/bin/vim "$@" ''; -- cgit v1.2.3 From ee5a1ddffe51117862f7e2669f3939dd165d5686 Mon Sep 17 00:00:00 2001 From: tv Date: Sun, 7 Feb 2016 08:09:07 +0100 Subject: tv vim: simplify wrapper --- tv/2configs/vim.nix | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'tv/2configs') diff --git a/tv/2configs/vim.nix b/tv/2configs/vim.nix index 8a6299a39..69a880dab 100644 --- a/tv/2configs/vim.nix +++ b/tv/2configs/vim.nix @@ -44,13 +44,9 @@ let alldirs = attrValues dirs ++ map dirOf (attrValues files); in unique (sort lessThan alldirs); - vim = pkgs.writeScriptBin "vim" '' - #! ${pkgs.dash}/bin/dash - set -f - umask=$(umask) - umask 0077 - ${concatStringsSep "\n" (map (x: "mkdir -p ${x}") mkdirs)} - umask "$umask" + vim = pkgs.writeDashBin "vim" '' + set -efu + (umask 0077; exec ${pkgs.coreutils}/bin/mkdir -p ${toString mkdirs}) exec ${pkgs.vim}/bin/vim "$@" ''; -- cgit v1.2.3 From 5a10c4beb56d052b816682058becedf7b8eacaaa Mon Sep 17 00:00:00 2001 From: tv Date: Mon, 8 Feb 2016 00:25:35 +0100 Subject: =?UTF-8?q?tv=20backup:=20xu:/home=20=E2=86=92=20wu:/bku/xu-home?= =?UTF-8?q?=20@=2006:00?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tv/2configs/backup.nix | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'tv/2configs') diff --git a/tv/2configs/backup.nix b/tv/2configs/backup.nix index f4d368557..6c90709a8 100644 --- a/tv/2configs/backup.nix +++ b/tv/2configs/backup.nix @@ -14,5 +14,17 @@ with lib; yearly = { format = "%Y"; }; }; }; + xu-home-wu = { + method = "push"; + src = { host = config.krebs.hosts.xu; path = "/home"; }; + dst = { host = config.krebs.hosts.wu; path = "/bku/xu-home"; }; + startAt = "06:00"; + snapshots = { + daily = { format = "%Y-%m-%d"; retain = 7; }; + weekly = { format = "%YW%W"; retain = 4; }; + monthly = { format = "%Y-%m"; retain = 12; }; + yearly = { format = "%Y"; }; + }; + }; }; } -- cgit v1.2.3 From d98578e3e190463a341a94f2cc778ef886f9252d Mon Sep 17 00:00:00 2001 From: tv Date: Mon, 8 Feb 2016 01:07:03 +0100 Subject: rm krebs.build.target --- tv/2configs/default.nix | 1 - 1 file changed, 1 deletion(-) (limited to 'tv/2configs') diff --git a/tv/2configs/default.nix b/tv/2configs/default.nix index 52d85f856..b5639af51 100644 --- a/tv/2configs/default.nix +++ b/tv/2configs/default.nix @@ -7,7 +7,6 @@ with lib; krebs.build = { user = config.krebs.users.tv; - target = mkDefault "root@${config.krebs.build.host.name}"; source = mapAttrs (_: mkDefault) ({ nixos-config = "symlink:stockholm/tv/1systems/${config.krebs.build.host.name}.nix"; nixpkgs = symlink:stockholm/nixpkgs; -- cgit v1.2.3 From 49ed93662983e67a8bef8641b4d6282e5a59b2f5 Mon Sep 17 00:00:00 2001 From: tv Date: Mon, 8 Feb 2016 04:12:56 +0100 Subject: tv git: bump descs --- tv/2configs/git.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'tv/2configs') diff --git a/tv/2configs/git.nix b/tv/2configs/git.nix index 3ee708e03..f248a8cb5 100644 --- a/tv/2configs/git.nix +++ b/tv/2configs/git.nix @@ -7,8 +7,8 @@ let out = { krebs.git = { enable = true; - root-title = "public repositories at ${config.krebs.build.host.name}"; - root-desc = "keep calm and engage"; + root-title = "repositories at ${config.krebs.build.host.name}"; + root-desc = "mostly krebs"; repos = repos; rules = rules; }; @@ -21,7 +21,7 @@ let rules = concatMap make-rules (attrValues repos); public-repos = mapAttrs make-public-repo ({ - } // mapAttrValues (setAttr "section" "1. Miscellaneous") { + } // mapAttrValues (setAttr "section" "1. miscellaneous") { cac-api = { desc = "CloudAtCost API command line interface"; }; @@ -37,7 +37,7 @@ let desc = "SoundCloud command line interface"; }; stockholm = { - desc = "take all the computers hostage, they'll love you!"; + desc = "NixOS configuration"; }; with-tmpdir = {}; } // mapAttrValues (setAttr "section" "2. Haskell libraries") { @@ -49,7 +49,7 @@ let web-routes-wai-custom = {}; xintmap = {}; xmonad-stockholm = {}; - } // mapAttrValues (setAttr "section" "3. Museum") { + } // mapAttrValues (setAttr "section" "3. museum") { cgserver = {}; crude-mail-setup = {}; dot-xmonad = {}; -- cgit v1.2.3 From 8b130a66287b829e7b6f9be0130df7231c7a6605 Mon Sep 17 00:00:00 2001 From: tv Date: Wed, 10 Feb 2016 19:06:32 +0100 Subject: krebs.nixpkgs.allowUnfreePredicate: init --- tv/2configs/hw/AO753.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tv/2configs') diff --git a/tv/2configs/hw/AO753.nix b/tv/2configs/hw/AO753.nix index 72a40819f..e7a2b9238 100644 --- a/tv/2configs/hw/AO753.nix +++ b/tv/2configs/hw/AO753.nix @@ -41,5 +41,5 @@ with lib; HandleSuspendKey=ignore ''; - nixpkgs.config.allowUnfreePredicate = pkg: hasPrefix "broadcom-sta-" pkg.name; + krebs.nixpkgs.allowUnfreePredicate = pkg: hasPrefix "broadcom-sta-" pkg.name; } -- cgit v1.2.3 From aeb179696aa515865690cd752592240ff7542c78 Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 11 Feb 2016 16:09:15 +0100 Subject: tv x220: remove unused stuff --- tv/2configs/hw/x220.nix | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'tv/2configs') diff --git a/tv/2configs/hw/x220.nix b/tv/2configs/hw/x220.nix index 7cec670fa..dac580865 100644 --- a/tv/2configs/hw/x220.nix +++ b/tv/2configs/hw/x220.nix @@ -5,18 +5,11 @@ ../smartd.nix ]; - boot.initrd.availableKernelModules = [ "ahci" ]; - boot.kernelModules = [ "kvm-intel" ]; - boot.loader.gummiboot.enable = true; boot.loader.efi.canTouchEfiVariables = true; networking.wireless.enable = true; - #hardware.enableAllFirmware = true; - #zramSwap.enable = true; - #zramSwap.numDevices = 2; - hardware.trackpoint = { enable = true; sensitivity = 220; @@ -50,10 +43,4 @@ Option "AccelMethod" "sna" ''; }; - - #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-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation Axes" 6 7 4 5 - #''; } -- cgit v1.2.3 From 7a6c4452e10d590e9f357be1a8b2ad1ebb05a015 Mon Sep 17 00:00:00 2001 From: tv Date: Thu, 11 Feb 2016 17:30:56 +0100 Subject: tv x220: rm AccepMethod sna --- tv/2configs/hw/x220.nix | 3 --- 1 file changed, 3 deletions(-) (limited to 'tv/2configs') diff --git a/tv/2configs/hw/x220.nix b/tv/2configs/hw/x220.nix index dac580865..9b3dd122a 100644 --- a/tv/2configs/hw/x220.nix +++ b/tv/2configs/hw/x220.nix @@ -39,8 +39,5 @@ services.xserver = { videoDriver = "intel"; vaapiDrivers = [ pkgs.vaapiIntel pkgs.vaapiVdpau ]; - deviceSection = '' - Option "AccelMethod" "sna" - ''; }; } -- cgit v1.2.3