From 8abbda9061c7fc3f04ca580a7435085cab8a8c83 Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 17 Jul 2018 19:33:13 +0200 Subject: reaktor-retiolum: +task-(add,delete,list) --- krebs/2configs/reaktor-retiolum.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/krebs/2configs/reaktor-retiolum.nix b/krebs/2configs/reaktor-retiolum.nix index b32d39b7e..d5f1851e3 100644 --- a/krebs/2configs/reaktor-retiolum.nix +++ b/krebs/2configs/reaktor-retiolum.nix @@ -10,6 +10,9 @@ with import ; }; plugins = with pkgs.ReaktorPlugins; [ sed-plugin + task-add + task-delete + task-list ] ++ (attrValues (todo "agenda")) ; -- cgit v1.2.3 From 0e9d94fff8cbf9b77e0b1d1b614704e133aa2062 Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 17 Jul 2018 19:47:49 +0200 Subject: j: remove trailing whitespaces --- jeschli/1systems/bln/config.nix | 2 +- jeschli/2configs/IM.nix | 2 +- jeschli/2configs/urxvt.nix | 4 ++-- jeschli/2configs/xserver/Xresources.nix | 2 +- jeschli/5pkgs/simple/xmonad-jeschli/default.nix | 6 +++--- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/jeschli/1systems/bln/config.nix b/jeschli/1systems/bln/config.nix index 371a7052d..716b9c484 100644 --- a/jeschli/1systems/bln/config.nix +++ b/jeschli/1systems/bln/config.nix @@ -1,7 +1,7 @@ { config, lib, pkgs, ... }: # bln config file { - imports = [ + imports = [ ./hardware-configuration.nix diff --git a/jeschli/2configs/IM.nix b/jeschli/2configs/IM.nix index 171b78242..288134fa2 100644 --- a/jeschli/2configs/IM.nix +++ b/jeschli/2configs/IM.nix @@ -30,7 +30,7 @@ in { jeschli-bln.pubkey jeschli-brauerei.pubkey ]; - packages = [ tmux ]; + packages = [ tmux ]; }; diff --git a/jeschli/2configs/urxvt.nix b/jeschli/2configs/urxvt.nix index 014918748..4049a47a3 100644 --- a/jeschli/2configs/urxvt.nix +++ b/jeschli/2configs/urxvt.nix @@ -29,11 +29,11 @@ with import ; *color13: rgb:fc/54/fc *color14: rgb:54/fc/fc *color15: rgb:fc/fc/fc - + URxvt*scrollBar: false URxvt*urgentOnBell: true URxvt*font: xft:DejaVu Sans Mono:pixelsize=${toString config.jeschliFontSize} URXvt*faceSize: ${toString config.jeschliFontSize} ''; - }; + }; } diff --git a/jeschli/2configs/xserver/Xresources.nix b/jeschli/2configs/xserver/Xresources.nix index e8154912c..adf06ee63 100644 --- a/jeschli/2configs/xserver/Xresources.nix +++ b/jeschli/2configs/xserver/Xresources.nix @@ -4,7 +4,7 @@ with import ; pkgs.writeText "Xresources" /* xdefaults */ '' Xcursor.theme: aero-large-drop - Xcursor.size: 128 + Xcursor.size: 128 Xft.dpi: 144 URxvt*cutchars: "\\`\"'&()*,;<=>?@[]^{|}‘’" diff --git a/jeschli/5pkgs/simple/xmonad-jeschli/default.nix b/jeschli/5pkgs/simple/xmonad-jeschli/default.nix index 5aa3c2f96..88856021c 100644 --- a/jeschli/5pkgs/simple/xmonad-jeschli/default.nix +++ b/jeschli/5pkgs/simple/xmonad-jeschli/default.nix @@ -90,7 +90,7 @@ mainNoArgs = do , startupHook = do setWMName "LG3D" whenJustM (liftIO (lookupEnv "XMONAD_STARTUP_HOOK")) - (\path -> forkFile path [] Nothing) <+> setWMName "LG3D" + (\path -> forkFile path [] Nothing) <+> setWMName "LG3D" , normalBorderColor = "#1c1c1c" , focusedBorderColor = "#f000b0" , handleEventHook = handleShutdownEvent @@ -150,7 +150,7 @@ myKeys conf = Map.fromList $ , ((_S , xK_Print ), gets windowset >>= allWorkspaceNames >>= pager pagerConfig (windows . W.shift) ) , ((_C , xK_Print ), toggleWS) , ((_4 , xK_Print ), rhombus horseConfig (liftIO . hPutStrLn stderr) ["Correct", "Horse", "Battery", "Staple", "Stuhl", "Tisch"] ) - + -- %! Rotate through the available layout algorithms , ((_4 , xK_space ), sendMessage NextLayout) , ((_4S , xK_space ), setLayout $ XMonad.layoutHook conf) -- reset layout @@ -222,7 +222,7 @@ myKeys conf = Map.fromList $ pagerConfig :: PagerConfig pagerConfig = def { pc_font = myFont - , pc_cellwidth = 256 + , pc_cellwidth = 256 --, pc_cellheight = 36 -- TODO automatically keep screen aspect --, pc_borderwidth = 1 --, pc_matchcolor = "#f0b000" -- cgit v1.2.3 From ecbfc932794aa5f1301e121876f244be7edcd133 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 18 Jul 2018 00:29:07 +0200 Subject: onebutton.r: use the latest unstable tarball as source this avoids cache misses and super expensive rebuilds on the raspi2 itself --- krebs/1systems/onebutton/source.nix | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/krebs/1systems/onebutton/source.nix b/krebs/1systems/onebutton/source.nix index 6842bfaab..91a998de7 100644 --- a/krebs/1systems/onebutton/source.nix +++ b/krebs/1systems/onebutton/source.nix @@ -1,11 +1,8 @@ with import ; let pkgs = import {}; - nixpkgs = pkgs.fetchFromGitHub { - owner = "nixos"; - repo = "nixpkgs-channels"; - rev = "nixos-unstable"; # only binary cache for unstable arm6 - sha256 = "1rqzh475xn43phagrr30lb0fd292c1s8as53irihsnd5wcksnbyd"; + nixpkgs = builtins.fetchTarball { + url = https://github.com/NixOS/nixpkgs-channels/archive/nixos-unstable.tar.gz; }; in import { name = "onebutton"; -- cgit v1.2.3 From e00a76d30e4514cb5164fb658552fc1589e749e4 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 18 Jul 2018 01:30:37 +0200 Subject: ma wbob.r: use mceusb --- makefu/1systems/wbob/config.nix | 7 ++++--- makefu/2configs/hw/mceusb.nix | 18 ++++++++++++++++++ 2 files changed, 22 insertions(+), 3 deletions(-) create mode 100644 makefu/2configs/hw/mceusb.nix diff --git a/makefu/1systems/wbob/config.nix b/makefu/1systems/wbob/config.nix index df317a016..7c81a2015 100644 --- a/makefu/1systems/wbob/config.nix +++ b/makefu/1systems/wbob/config.nix @@ -43,16 +43,18 @@ in { # + (let collectd-port = 25826; influx-port = 8086; + admin-port = 8083; grafana-port = 3000; # TODO nginx forward db = "collectd_db"; logging-interface = "enp0s25"; in { - networking.firewall.allowedTCPPorts = [ 3000 ]; + networking.firewall.allowedTCPPorts = [ 3000 influx-port admin-port ]; services.grafana.enable = true; services.grafana.addr = "0.0.0.0"; @@ -61,7 +63,7 @@ in { meta.hostname = config.krebs.build.host.name; # meta.logging-enabled = true; http.bind-address = ":${toString influx-port}"; - admin.bind-address = ":8083"; + admin.bind-address = ":${toString admin-port}"; collectd = [{ enabled = true; typesdb = "${pkgs.collectd}/share/collectd/types.db"; @@ -125,7 +127,6 @@ in { networking.firewall.allowedTCPPorts = [ 655 8081 #smokeping - 8086 #influx 49152 ]; networking.firewall.trustedInterfaces = [ "enp0s25" ]; diff --git a/makefu/2configs/hw/mceusb.nix b/makefu/2configs/hw/mceusb.nix new file mode 100644 index 000000000..c1d6f5651 --- /dev/null +++ b/makefu/2configs/hw/mceusb.nix @@ -0,0 +1,18 @@ +{pkgs,...}:{ + # Disable the MCE remote from acting like a keyboard. (We use lirc instead.) + services.xserver.inputClassSections = ['' + Identifier "MCE USB Keyboard mimic blacklist" + Driver "mceusb" + MatchProduct "Media Center Ed. eHome Infrared Remote Transceiver (1934:5168)" + Option "Ignore" "on" + '']; + boot.kernelPackages = builtins.trace "Using linux kernel 4.16, not latest" pkgs.linuxPackages_4_16; + nixpkgs.config.packageOverrides = pkgs: { + linux_4_16 = pkgs.linux_4_16.override { + extraConfig = '' + LIRC y + ''; + }; + }; + +} -- cgit v1.2.3 From 46e725b6ee1259ad8a0d33f9ffbda6fd1dc2228d Mon Sep 17 00:00:00 2001 From: jeschli Date: Sun, 22 Jul 2018 08:32:14 +0200 Subject: reaktor: task-remove -> task-delete --- krebs/5pkgs/simple/Reaktor/plugins.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/krebs/5pkgs/simple/Reaktor/plugins.nix b/krebs/5pkgs/simple/Reaktor/plugins.nix index db578c457..c6e601475 100644 --- a/krebs/5pkgs/simple/Reaktor/plugins.nix +++ b/krebs/5pkgs/simple/Reaktor/plugins.nix @@ -165,7 +165,7 @@ rec { }; task-delete = buildSimpleReaktorPlugin "task-delete" { - pattern = "^task-remove: (?P.*)$$"; + pattern = "^task-delete: (?P.*)$$"; script = pkgs.writeDash "task-delete" '' ${pkgs.taskwarrior}/bin/task rc:${taskrcFile} delete "$*" ''; -- cgit v1.2.3 From b699a206dd28ce81c32401b36cae9219b1efd425 Mon Sep 17 00:00:00 2001 From: lassulus Date: Wed, 25 Jul 2018 10:16:50 +0200 Subject: nixpkgs: 56fad14 -> d6c6c7f --- krebs/krops.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/krebs/krops.nix b/krebs/krops.nix index 861f2d323..91b27f17d 100644 --- a/krebs/krops.nix +++ b/krebs/krops.nix @@ -12,7 +12,7 @@ krebs-source = { nixpkgs.git = { - ref = "56fad146a12a6f934d1d5ef875eb729be1b19129"; + ref = "d6c6c7fcec6dbd2b8ab14f0b35d56c7733872baa"; url = https://github.com/NixOS/nixpkgs; }; stockholm.file = toString ../.; -- cgit v1.2.3 From 45a93b32a646a57a4edd7e1febf6d1be373a69da Mon Sep 17 00:00:00 2001 From: makefu Date: Thu, 26 Jul 2018 21:50:16 +0200 Subject: ma owncloud: add required zend_extension to enable opcache --- makefu/2configs/deployment/owncloud.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/makefu/2configs/deployment/owncloud.nix b/makefu/2configs/deployment/owncloud.nix index e9d4b18e0..b3ea7ed4e 100644 --- a/makefu/2configs/deployment/owncloud.nix +++ b/makefu/2configs/deployment/owncloud.nix @@ -108,7 +108,6 @@ let # Add headers to serve security related headers add_header Strict-Transport-Security "max-age=15768000; includeSubDomains; preload;"; add_header X-Content-Type-Options nosniff; - add_header X-Frame-Options "SAMEORIGIN"; add_header X-XSS-Protection "1; mode=block"; add_header X-Robots-Tag none; # Optional: Don't log access to assets @@ -144,6 +143,7 @@ let opcache.memory_consumption=128 opcache.save_comments=1 opcache.revalidate_freq=1 + zend_extension=${pkgs.php}/lib/php/extensions/opcache.so display_errors = on display_startup_errors = on -- cgit v1.2.3 From 579a6d257b255122a51c6966395a9cc21279dab6 Mon Sep 17 00:00:00 2001 From: makefu Date: Thu, 26 Jul 2018 22:09:55 +0200 Subject: ma stats/client: disable tracefs --- makefu/2configs/stats/client.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/makefu/2configs/stats/client.nix b/makefu/2configs/stats/client.nix index dd6ddddaf..cfb5e3fd2 100644 --- a/makefu/2configs/stats/client.nix +++ b/makefu/2configs/stats/client.nix @@ -31,6 +31,7 @@ FSType "tmpfs" FSType "binfmt_misc" FSType "debugfs" + FSType "tracefs" FSType "mqueue" FSType "hugetlbfs" FSType "systemd-1" -- cgit v1.2.3 From 54990bce8941dfc9b38504fbff357cadd66354a3 Mon Sep 17 00:00:00 2001 From: makefu Date: Thu, 26 Jul 2018 22:34:47 +0200 Subject: ma owncloud: enable owncloud cron service --- makefu/2configs/deployment/owncloud.nix | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/makefu/2configs/deployment/owncloud.nix b/makefu/2configs/deployment/owncloud.nix index b3ea7ed4e..cfde0aba8 100644 --- a/makefu/2configs/deployment/owncloud.nix +++ b/makefu/2configs/deployment/owncloud.nix @@ -143,6 +143,7 @@ let opcache.memory_consumption=128 opcache.save_comments=1 opcache.revalidate_freq=1 + opcache.file_cache = .opcache zend_extension=${pkgs.php}/lib/php/extensions/opcache.so display_errors = on @@ -155,6 +156,13 @@ let extension=${pkgs.phpPackages.redis}/lib/php/extensions/redis.so extension=${pkgs.phpPackages.apcu}/lib/php/extensions/apcu.so ''; + systemd.services."nextcloud-cron-${domain}" = { + serviceConfig = { + User = "nginx"; + ExecStart = "${pkgs.php}/bin/php -f ${root}/cron.php"; + }; + startAt = "*:0/15"; + }; }; in { imports = [ -- cgit v1.2.3 From f23679254c9cebdae8cbd6fb54a9cb2dcf3f63ed Mon Sep 17 00:00:00 2001 From: lassulus Date: Sat, 28 Jul 2018 00:52:20 +0200 Subject: l: add hackbeach@lassul.us --- lass/2configs/dcso-dev.nix | 10 ++++------ lass/2configs/exim-smarthost.nix | 1 + 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/lass/2configs/dcso-dev.nix b/lass/2configs/dcso-dev.nix index 4d8d308fb..b79d91148 100644 --- a/lass/2configs/dcso-dev.nix +++ b/lass/2configs/dcso-dev.nix @@ -52,6 +52,10 @@ in { { predicate = "-p tcp --dport 9000"; target = "ACCEPT";} ]; + krebs.iptables.tables.filter.OUTPUT.rules = [ + { predicate = "-p tcp --dport 21"; target = "REJECT";} + ]; + krebs.per-user.dev.packages = [ pkgs.go ]; @@ -64,12 +68,6 @@ in { networking.interfaces.et0.ipv4.addresses = [ { address = "10.99.23.1"; prefixLength = 24; } ]; - virtualisation.docker.enable = true; - environment.etc."docker/daemon.json".source = pkgs.writeText "daemon.json" '' - { - "bip": "172.25.0.1/16" - } - ''; services.rabbitmq.enable = true; services.postgresql.enable = true; } diff --git a/lass/2configs/exim-smarthost.nix b/lass/2configs/exim-smarthost.nix index db6bda005..30757964c 100644 --- a/lass/2configs/exim-smarthost.nix +++ b/lass/2configs/exim-smarthost.nix @@ -84,6 +84,7 @@ with import ; { from = "boardgamegeek@lassul.us"; to = lass.mail; } { from = "qwertee@lassul.us"; to = lass.mail; } { from = "zazzle@lassul.us"; to = lass.mail; } + { from = "hackbeach@lassul.us"; to = lass.mail; } ]; system-aliases = [ { from = "mailer-daemon"; to = "postmaster"; } -- cgit v1.2.3 From 930daa1aefb57012177d0a9b8375d9dc46666315 Mon Sep 17 00:00:00 2001 From: lassulus Date: Sat, 28 Jul 2018 19:08:26 +0200 Subject: l: add knav --- lass/5pkgs/knav/default.nix | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 lass/5pkgs/knav/default.nix diff --git a/lass/5pkgs/knav/default.nix b/lass/5pkgs/knav/default.nix new file mode 100644 index 000000000..30d49a1b3 --- /dev/null +++ b/lass/5pkgs/knav/default.nix @@ -0,0 +1,26 @@ +{ pkgs, ... }: let + + keynavrc = pkgs.writeText "keynavrc" '' + clear + Escape quit + q record ~/.keynav_macros + shift+at playback + u history-back + a cut-left + s cut-down + w cut-up + d cut-right + shift+a move-left + shift+s move-down + shift+w move-up + shift+d move-right + t windowzoom + c cursorzoom 300 300 + e warp + 1 click 1 + 2 click 2 + 3 click 3 + ''; +in pkgs.writeScriptBin "knav" '' + ${pkgs.keynav}/bin/keynav "loadconfig ${keynavrc}, start" +'' -- cgit v1.2.3 From 0ec07618c28acd7bf040d73d320bbfa4af6b7d04 Mon Sep 17 00:00:00 2001 From: lassulus Date: Sat, 28 Jul 2018 19:13:21 +0200 Subject: l helios.r: remove docker --- lass/1systems/helios/config.nix | 3 +-- lass/2configs/dcso-dev.nix | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/lass/1systems/helios/config.nix b/lass/1systems/helios/config.nix index 5657742a6..40150b80e 100644 --- a/lass/1systems/helios/config.nix +++ b/lass/1systems/helios/config.nix @@ -98,7 +98,7 @@ with import ; ]; programs.adb.enable = true; - users.users.mainUser.extraGroups = [ "adbusers" "docker" ]; + users.users.mainUser.extraGroups = [ "adbusers" ]; services.printing.drivers = [ pkgs.postscript-lexmark ]; @@ -106,5 +106,4 @@ with import ; HandleLidSwitch=ignore ''; - virtualisation.docker.enable = true; } diff --git a/lass/2configs/dcso-dev.nix b/lass/2configs/dcso-dev.nix index b79d91148..830acb2e1 100644 --- a/lass/2configs/dcso-dev.nix +++ b/lass/2configs/dcso-dev.nix @@ -9,7 +9,7 @@ in { dev = { name = "dev"; uid = genid "dev"; - extraGroups = [ "docker" "vboxusers" ]; + extraGroups = [ "vboxusers" ]; description = "user for collaborative development"; home = "/home/dev"; useDefaultShell = true; -- cgit v1.2.3 From 4d36de3665faad78bc8fb90172ec51e835adcc7b Mon Sep 17 00:00:00 2001 From: lassulus Date: Sat, 28 Jul 2018 19:14:53 +0200 Subject: l blue: add git-preview --- lass/2configs/blue.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/lass/2configs/blue.nix b/lass/2configs/blue.nix index 363705edc..16c63ff38 100644 --- a/lass/2configs/blue.nix +++ b/lass/2configs/blue.nix @@ -12,6 +12,7 @@ with (import ); environment.systemPackages = with pkgs; [ ag nmap + git-preview ]; services.tor.enable = true; -- cgit v1.2.3 From ac86476a3b3a75d6f3ee5541a3675ed7f9bfeb84 Mon Sep 17 00:00:00 2001 From: lassulus Date: Sat, 28 Jul 2018 19:16:23 +0200 Subject: l xmonad: add knav binding --- lass/5pkgs/custom/xmonad-lass/default.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lass/5pkgs/custom/xmonad-lass/default.nix b/lass/5pkgs/custom/xmonad-lass/default.nix index 694f3c033..8b508ae6a 100644 --- a/lass/5pkgs/custom/xmonad-lass/default.nix +++ b/lass/5pkgs/custom/xmonad-lass/default.nix @@ -160,6 +160,8 @@ myKeyMap = , ("", spawn "${pkgs.xcalib}/bin/xcalib -invert -alter") + , ("M4-s", spawn "${pkgs.knav}/bin/knav") + --, ("M4-w", screenWorkspace 0 >>= (windows . W.greedyView)) --, ("M4-e", screenWorkspace 1 >>= (windows . W.greedyView)) --, ("M4-r", screenWorkspace 2 >>= (windows . W.greedyView)) -- cgit v1.2.3 From fe1d0ddb5a3106f0fb910febc385db1555ec5e8d Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 30 Jul 2018 16:02:31 +0200 Subject: l browsers: add krebsgold --- lass/2configs/browsers.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/lass/2configs/browsers.nix b/lass/2configs/browsers.nix index 272169e92..64fa6573a 100644 --- a/lass/2configs/browsers.nix +++ b/lass/2configs/browsers.nix @@ -66,6 +66,7 @@ in { extensions = [ "cjpalhdlnbpafiamejdnhcphjbkeiagm" # ublock origin "dbepggeogbaibhgnhhndojpepiihcmeb" # vimium + "liloimnbhkghhdhlamdjipkmadhpcjmn" # krebsgold ]; }; -- cgit v1.2.3 From 2c4e70773193172ab2d694dd111f55dbaf708b1f Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 16:30:31 +0200 Subject: j bln: new office vpn --- jeschli/1systems/bln/config.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/jeschli/1systems/bln/config.nix b/jeschli/1systems/bln/config.nix index 371a7052d..2c8c9383c 100644 --- a/jeschli/1systems/bln/config.nix +++ b/jeschli/1systems/bln/config.nix @@ -9,6 +9,8 @@ +# + ]; # boot.loader.systemd-boot.enable = true; @@ -94,6 +96,8 @@ vagrant # document viewer zathura + + samba ]; -- cgit v1.2.3 From d34cfa4cc8953ee227f99a36d56ec9335cba532e Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 16:32:39 +0200 Subject: j my-emacs: cooler feel for org-mode --- jeschli/2configs/emacs.nix | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/jeschli/2configs/emacs.nix b/jeschli/2configs/emacs.nix index 4c52432d3..2089d4254 100644 --- a/jeschli/2configs/emacs.nix +++ b/jeschli/2configs/emacs.nix @@ -17,18 +17,19 @@ let ''; evilMode = '' ;; Evil Mode - (add-to-list 'load-path "~/.emacs.d/evil") (require 'evil) (evil-mode 1) - (require 'evil-org) - (add-hook 'org-mode-hook 'evil-org-mode) - (evil-org-set-key-theme '(navigation insert textobjects additional calendar)) - (require 'evil-org-agenda) - (evil-org-agenda-set-keys) + ;; (require 'evil-org) + ;; (add-hook 'org-mode-hook 'evil-org-mode) + ;; (evil-org-set-key-theme '(navigation insert textobjects additional calendar)) + ;; (require 'evil-org-agenda) + ;; (evil-org-agenda-set-keys) ''; windowCosmetics = '' + (menu-bar-mode -1) (tool-bar-mode -1) ; Disable the button bar atop screen (scroll-bar-mode -1) ; Disable scroll bar + (toggle-scroll-bar -1) (setq inhibit-startup-screen t) ; Disable startup screen with graphics (setq-default indent-tabs-mode nil) ; Use spaces instead of tabs (setq default-tab-width 2) ; Two spaces is a tab @@ -41,11 +42,15 @@ let (global-set-key "\C-cl" 'org-store-link) (global-set-key "\C-ca" 'org-agenda) (global-set-key "\C-cb" 'org-iswitchb) + (setq org-link-frame-setup '((file . find-file))) ; open link in same frame. (if (boundp 'org-user-agenda-files) (setq org-agenda-files org-user-agenda-files) (setq org-agenda-files (quote ("~/projects/notes"))) ) ''; + theme = '' + (load-theme 'monokai-alt) + ''; recentFiles = '' (recentf-mode 1) (setq recentf-max-menu-items 25) @@ -55,14 +60,17 @@ let ${packageRepos} ${orgMode} ${recentFiles} + ${theme} ${windowCosmetics} ''; emacsWithCustomPackages = (pkgs.emacsPackagesNgGen pkgs.emacs).emacsWithPackages (epkgs: [ + epkgs.melpaPackages.evil epkgs.melpaStablePackages.magit epkgs.melpaPackages.mmm-mode epkgs.melpaPackages.nix-mode epkgs.melpaPackages.go-mode epkgs.melpaPackages.google-this + epkgs.melpaPackages.monokai-alt-theme ]); myEmacs = pkgs.writeDashBin "my-emacs" '' exec ${emacsWithCustomPackages}/bin/emacs -q -l ${dotEmacs} "$@" -- cgit v1.2.3 From 63a761b4da5262749c4cb122739666d412456776 Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 16:36:51 +0200 Subject: j: +officevpn by luis --- jeschli/2configs/officevpn.nix | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 jeschli/2configs/officevpn.nix diff --git a/jeschli/2configs/officevpn.nix b/jeschli/2configs/officevpn.nix new file mode 100644 index 000000000..eb0477d51 --- /dev/null +++ b/jeschli/2configs/officevpn.nix @@ -0,0 +1,19 @@ +{ config, pkgs, ... }: + +{ + nixpkgs.config.packageOverrides = pkgs: { + openvpn = pkgs.openvpn.override { pkcs11Support = true; useSystemd = false;}; + }; + + environment.systemPackages = with pkgs; [ + opensc + openvpn + yubikey-manager + ]; + + services.pcscd.enable = true; + + # To start the vpn manually execute + # $ openvpn --config clien.ovpn +} + -- cgit v1.2.3 From 41419e11f030e176c5b2f2d4fe0c509e9ad11239 Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 19:19:32 +0200 Subject: j brauerei: remove some comment garbage --- jeschli/1systems/brauerei/config.nix | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/jeschli/1systems/brauerei/config.nix b/jeschli/1systems/brauerei/config.nix index 5a6ad7652..00db1ad15 100644 --- a/jeschli/1systems/brauerei/config.nix +++ b/jeschli/1systems/brauerei/config.nix @@ -25,21 +25,11 @@ preLVM = true; allowDiscards = true; } ]; -# networking.hostName = "brauerei"; - # Define your hostname. -# networking.wireless.enable = true; networking.networkmanager.enable = true; - # Enables wireless support via wpa_supplicant. - # Select internationalisation properties. - # i18n = { - # consoleFont = "Lat2-Terminus16"; - # consoleKeyMap = "us"; - # defaultLocale = "en_US.UTF-8"; - # }; - # Set your time zone. # time.timeZone = "Europe/Amsterdam"; + nixpkgs.config.allowUnfree = true; - # List packages installed in system profile. To search by name, run: # $ nix-env -qaP | grep wget + environment.shellAliases = { n = "nix-shell"; stocki = pkgs.writeDash "deploy" '' -- cgit v1.2.3 From 433b5a442bfb06ca2ed5e6ed5a0a7b43c0b4ad64 Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 19:19:55 +0200 Subject: j brauerei: reformatting --- jeschli/1systems/brauerei/config.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/jeschli/1systems/brauerei/config.nix b/jeschli/1systems/brauerei/config.nix index 00db1ad15..26e25c829 100644 --- a/jeschli/1systems/brauerei/config.nix +++ b/jeschli/1systems/brauerei/config.nix @@ -37,6 +37,7 @@ exec nix-shell -I stockholm="$PWD" --run 'deploy --system="brauerei"' ''; }; + environment.systemPackages = with pkgs; [ # system helper ag -- cgit v1.2.3 From 379b226235f850919d72957579cad5cf052c42e5 Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 19:20:09 +0200 Subject: j brauerei: +taskwarrior --- jeschli/1systems/brauerei/config.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/jeschli/1systems/brauerei/config.nix b/jeschli/1systems/brauerei/config.nix index 26e25c829..5b384d18f 100644 --- a/jeschli/1systems/brauerei/config.nix +++ b/jeschli/1systems/brauerei/config.nix @@ -94,6 +94,7 @@ zathura # xorg xorg.xbacklight + taskwarrior ]; # Some programs need SUID wrappers, can be configured further or are -- cgit v1.2.3 From 29f65c27655136356354cb96e0ee3676db09dd67 Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 19:20:29 +0200 Subject: j brauerei: *dpi --- jeschli/1systems/brauerei/config.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jeschli/1systems/brauerei/config.nix b/jeschli/1systems/brauerei/config.nix index 5b384d18f..d1cca55a6 100644 --- a/jeschli/1systems/brauerei/config.nix +++ b/jeschli/1systems/brauerei/config.nix @@ -118,7 +118,7 @@ display = 11; tty = 11; - dpi = 96; + dpi = 144; # videoDrivers = [ "nvidia" ]; synaptics = { -- cgit v1.2.3 From 50190d3765cbf72205c410950322dbb2ef70c111 Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 19:21:30 +0200 Subject: j brauerei: add audio group for jeschli --- jeschli/1systems/brauerei/config.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jeschli/1systems/brauerei/config.nix b/jeschli/1systems/brauerei/config.nix index d1cca55a6..e200cbcd4 100644 --- a/jeschli/1systems/brauerei/config.nix +++ b/jeschli/1systems/brauerei/config.nix @@ -130,7 +130,7 @@ users.extraUsers.jeschli = { # TODO: define as krebs.users isNormalUser = true; - extraGroups = ["docker" "vboxusers"]; + extraGroups = ["docker" "vboxusers" "audio"]; uid = 1000; }; users.extraUsers.jamie = { -- cgit v1.2.3 From 84b75261c238fb5ae65137a8b33b51666e8db079 Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 19:22:32 +0200 Subject: j brauerei: enable pulseaudio --- jeschli/1systems/brauerei/hardware-configuration.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/jeschli/1systems/brauerei/hardware-configuration.nix b/jeschli/1systems/brauerei/hardware-configuration.nix index 75fdb89fd..2cb3e6661 100644 --- a/jeschli/1systems/brauerei/hardware-configuration.nix +++ b/jeschli/1systems/brauerei/hardware-configuration.nix @@ -29,5 +29,6 @@ swapDevices = [ ]; + hardware.pulseaudio.enable = true; nix.maxJobs = lib.mkDefault 4; } -- cgit v1.2.3 From 101733029e93a2d3ee8de8ed1d6039aacb010a4e Mon Sep 17 00:00:00 2001 From: jeschli Date: Tue, 31 Jul 2018 19:23:29 +0200 Subject: j xserver: remove xft.dpi option --- jeschli/2configs/xserver/Xresources.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/jeschli/2configs/xserver/Xresources.nix b/jeschli/2configs/xserver/Xresources.nix index adf06ee63..98f325256 100644 --- a/jeschli/2configs/xserver/Xresources.nix +++ b/jeschli/2configs/xserver/Xresources.nix @@ -5,7 +5,6 @@ with import ; pkgs.writeText "Xresources" /* xdefaults */ '' Xcursor.theme: aero-large-drop Xcursor.size: 128 - Xft.dpi: 144 URxvt*cutchars: "\\`\"'&()*,;<=>?@[]^{|}‘’" URxvt*eightBitInput: false -- cgit v1.2.3 From d487c1b5c2a34de41376dddfb39224719d3d81c4 Mon Sep 17 00:00:00 2001 From: jeschli Date: Wed, 1 Aug 2018 13:53:46 +0200 Subject: j emacs: activate evilMode --- jeschli/2configs/emacs.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/jeschli/2configs/emacs.nix b/jeschli/2configs/emacs.nix index 2089d4254..3bd2dbfc4 100644 --- a/jeschli/2configs/emacs.nix +++ b/jeschli/2configs/emacs.nix @@ -57,6 +57,7 @@ let (global-set-key "\C-x\ \C-r" 'recentf-open-files) ''; dotEmacs = pkgs.writeText "dot-emacs" '' + ${evilMode} ${packageRepos} ${orgMode} ${recentFiles} -- cgit v1.2.3 From dbbf237393468b49f07beaeea614e12bac35a6c2 Mon Sep 17 00:00:00 2001 From: jeschli Date: Wed, 1 Aug 2018 13:55:10 +0200 Subject: krebs git: refactor --- krebs/3modules/git.nix | 60 ++++++++++++++++++++------------------------------ 1 file changed, 24 insertions(+), 36 deletions(-) diff --git a/krebs/3modules/git.nix b/krebs/3modules/git.nix index 5ae24b40b..6311e88ab 100644 --- a/krebs/3modules/git.nix +++ b/krebs/3modules/git.nix @@ -8,6 +8,21 @@ with import ; let + defaultBool = o: mkOption { + type = types.bool; + default = option; + }; + + defaultUint = o: mkOption { + type = types.uint; + default = o; + }; + + defaultAbsolutpath = o: mkOption { + type = types.absolute-pathname; + default = o; + }; + cfg = config.krebs.git; out = { @@ -121,42 +136,15 @@ let cgit-settings = types.submodule { # A setting's value of `null` means cgit's default should be used. options = { - cache-root = mkOption { - type = types.absolute-pathname; - default = "/tmp/cgit"; - }; - cache-size = mkOption { - type = types.uint; - default = 1000; - }; - css = mkOption { - type = types.absolute-pathname; - default = "/static/cgit.css"; - }; - enable-commit-graph = mkOption { - type = types.bool; - default = true; - }; - enable-index-links = mkOption { - type = types.bool; - default = true; - }; - enable-index-owner = mkOption { - type = types.bool; - default = false; - }; - enable-log-filecount = mkOption { - type = types.bool; - default = true; - }; - enable-log-linecount = mkOption { - type = types.bool; - default = true; - }; - enable-remote-branches = mkOption { - type = types.bool; - default = true; - }; + cache-root = defaultAbsolutpath("/tmp/cgit"); + cache-size = defaultUint(1000); + css = defaultAbsolutpath("/static/cgit.css"); + enable-commit-graph = defaultBool(true); + enable-index-links = defaultBool(true); + enable-index-owner = defaultBool(false); + enable-log-filecount = defaultBool(true); + enable-log-linecount = defaultBool(true); + enable-remote-branches = defaultBool(true); logo = mkOption { type = types.absolute-pathname; default = "/static/cgit.png"; -- cgit v1.2.3 From 49bfd805d525889c191137800892ce254f2c4c0b Mon Sep 17 00:00:00 2001 From: jeschli Date: Wed, 1 Aug 2018 14:02:54 +0200 Subject: j bln: +pair programming eth link --- jeschli/1systems/bln/config.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/jeschli/1systems/bln/config.nix b/jeschli/1systems/bln/config.nix index e17d5a41b..6e3c3bec8 100644 --- a/jeschli/1systems/bln/config.nix +++ b/jeschli/1systems/bln/config.nix @@ -165,4 +165,9 @@ hardware.bluetooth.enable = true; krebs.build.host = config.krebs.hosts.bln; + + networking.interfaces.enp0s31f6.ipv4.addresses = [ + { address = "10.99.23.2"; prefixLength = 24; } + ]; + } -- cgit v1.2.3 From 33577e0fb43fd6539c53d4dae25dfdc9b540b0e2 Mon Sep 17 00:00:00 2001 From: jeschli Date: Wed, 1 Aug 2018 14:05:29 +0200 Subject: j xserver: removed dpi; modified urxvt font-size --- jeschli/2configs/xserver/Xresources.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jeschli/2configs/xserver/Xresources.nix b/jeschli/2configs/xserver/Xresources.nix index adf06ee63..ebe7159ff 100644 --- a/jeschli/2configs/xserver/Xresources.nix +++ b/jeschli/2configs/xserver/Xresources.nix @@ -5,7 +5,6 @@ with import ; pkgs.writeText "Xresources" /* xdefaults */ '' Xcursor.theme: aero-large-drop Xcursor.size: 128 - Xft.dpi: 144 URxvt*cutchars: "\\`\"'&()*,;<=>?@[]^{|}‘’" URxvt*eightBitInput: false @@ -22,7 +21,8 @@ pkgs.writeText "Xresources" /* xdefaults */ '' URxvt*charClass: 33:48,37:48,45-47:48,64:48,38:48,61:48,63:48 URxvt*cutNewline: False URxvt*cutToBeginningOfLine: False - + URxvt*font: xft:Monospace:size=12 + URxvt*font: xft:Monospace:size=12:bold URxvt*color0: #232342 URxvt*color3: #c07000 URxvt*color4: #4040c0 -- cgit v1.2.3 From 2adea5b2cc789a2dd86a417cc47e0cc6adc80b5f Mon Sep 17 00:00:00 2001 From: lassulus Date: Sat, 4 Aug 2018 08:04:00 +0200 Subject: news: kill some broken feeds --- krebs/2configs/news-spam.nix | 4 ---- 1 file changed, 4 deletions(-) diff --git a/krebs/2configs/news-spam.nix b/krebs/2configs/news-spam.nix index a3f39b40e..88b7e1072 100644 --- a/krebs/2configs/news-spam.nix +++ b/krebs/2configs/news-spam.nix @@ -7,7 +7,6 @@ [SPAM]aje|http://www.aljazeera.com/Services/Rss/?PostingId=2007731105943979989|#snews [SPAM]allafrica|http://allafrica.com/tools/headlines/rdf/latest/headlines.rdf|#snews [SPAM]antirez|http://antirez.com/rss|#snews - [SPAM]arbor|http://feeds2.feedburner.com/asert/|#snews [SPAM]archlinux|http://www.archlinux.org/feeds/news/|#snews [SPAM]ars|http://feeds.arstechnica.com/arstechnica/index?format=xml|#snews [SPAM]augustl|http://augustl.com/atom.xml|#snews @@ -131,7 +130,6 @@ [SPAM]slashdot|http://rss.slashdot.org/Slashdot/slashdot|#snews [SPAM]slate|http://feeds.slate.com/slate|#snews [SPAM]spiegel_eil|http://www.spiegel.de/schlagzeilen/eilmeldungen/index.rss|#snews - [SPAM]spiegelfechter|http://feeds.feedburner.com/DerSpiegelfechter?format=xml|#snews [SPAM]spiegel_top|http://www.spiegel.de/schlagzeilen/tops/index.rss|#snews [SPAM]standardmedia_ke|http://www.standardmedia.co.ke/rss/headlines.php|#snews [SPAM]stern|http://www.stern.de/feed/standard/all/|#snews @@ -146,7 +144,6 @@ [SPAM]the_insider|http://www.theinsider.org/rss/news/headlines-xml.asp|#snews [SPAM]tigsource|http://www.tigsource.com/feed/|#snews [SPAM]tinc|http://tinc-vpn.org/news/index.rss|#snews - [SPAM]topix_b|http://www.topix.com/rss/wire/de/berlin|#snews [SPAM]torr_bits|http://feeds.feedburner.com/TorrentfreakBits|#snews [SPAM]torrentfreak|http://feeds.feedburner.com/Torrentfreak|#snews [SPAM]torr_news|http://feed.torrentfreak.com/Torrentfreak/|#snews @@ -160,7 +157,6 @@ [SPAM]us_math_society|http://www.ams.org/cgi-bin/content/news_items.cgi?rss=1|#snews [SPAM]vimperator|https://sites.google.com/a/vimperator.org/www/blog/posts.xml|#snews [SPAM]weechat|http://dev.weechat.org/feed/atom|#snews - [SPAM]wp_world|http://feeds.washingtonpost.com/rss/rss_blogpost|#snews [SPAM]xkcd|https://xkcd.com/rss.xml|#snews [SPAM]zdnet|http://www.zdnet.com/news/rss.xml|#snews ''; -- cgit v1.2.3 From 809ded98e77eca001576ffdec4b4b1d85209e715 Mon Sep 17 00:00:00 2001 From: lassulus Date: Sat, 4 Aug 2018 11:42:33 +0200 Subject: nixpkgs: d6c6c7f -> d0c868e --- krebs/krops.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/krebs/krops.nix b/krebs/krops.nix index 91b27f17d..0e80aec0e 100644 --- a/krebs/krops.nix +++ b/krebs/krops.nix @@ -12,7 +12,7 @@ krebs-source = { nixpkgs.git = { - ref = "d6c6c7fcec6dbd2b8ab14f0b35d56c7733872baa"; + ref = "d0c868ec17c2cb2ca845f33fbfe381e9c7e55516"; url = https://github.com/NixOS/nixpkgs; }; stockholm.file = toString ../.; -- cgit v1.2.3 From f00277e3ecaf322c88b6984df8e8a2849bc3be4a Mon Sep 17 00:00:00 2001 From: lassulus Date: Sat, 4 Aug 2018 11:48:42 +0200 Subject: Revert "krebs git: refactor" This reverts commit dbbf237393468b49f07beaeea614e12bac35a6c2. --- krebs/3modules/git.nix | 60 ++++++++++++++++++++++++++++++-------------------- 1 file changed, 36 insertions(+), 24 deletions(-) diff --git a/krebs/3modules/git.nix b/krebs/3modules/git.nix index 6311e88ab..5ae24b40b 100644 --- a/krebs/3modules/git.nix +++ b/krebs/3modules/git.nix @@ -8,21 +8,6 @@ with import ; let - defaultBool = o: mkOption { - type = types.bool; - default = option; - }; - - defaultUint = o: mkOption { - type = types.uint; - default = o; - }; - - defaultAbsolutpath = o: mkOption { - type = types.absolute-pathname; - default = o; - }; - cfg = config.krebs.git; out = { @@ -136,15 +121,42 @@ let cgit-settings = types.submodule { # A setting's value of `null` means cgit's default should be used. options = { - cache-root = defaultAbsolutpath("/tmp/cgit"); - cache-size = defaultUint(1000); - css = defaultAbsolutpath("/static/cgit.css"); - enable-commit-graph = defaultBool(true); - enable-index-links = defaultBool(true); - enable-index-owner = defaultBool(false); - enable-log-filecount = defaultBool(true); - enable-log-linecount = defaultBool(true); - enable-remote-branches = defaultBool(true); + cache-root = mkOption { + type = types.absolute-pathname; + default = "/tmp/cgit"; + }; + cache-size = mkOption { + type = types.uint; + default = 1000; + }; + css = mkOption { + type = types.absolute-pathname; + default = "/static/cgit.css"; + }; + enable-commit-graph = mkOption { + type = types.bool; + default = true; + }; + enable-index-links = mkOption { + type = types.bool; + default = true; + }; + enable-index-owner = mkOption { + type = types.bool; + default = false; + }; + enable-log-filecount = mkOption { + type = types.bool; + default = true; + }; + enable-log-linecount = mkOption { + type = types.bool; + default = true; + }; + enable-remote-branches = mkOption { + type = types.bool; + default = true; + }; logo = mkOption { type = types.absolute-pathname; default = "/static/cgit.png"; -- cgit v1.2.3 From 75e8c9639e767fb68b6191892ea17894f7e9ab63 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 16:27:42 +0200 Subject: ma tools: s/krebs.per-user/users.users/ --- makefu/2configs/task-client.nix | 2 +- makefu/2configs/tools/core-gui.nix | 4 ++-- makefu/2configs/tools/desktop.nix | 2 ++ makefu/2configs/tools/extra-gui.nix | 2 +- makefu/2configs/tools/media.nix | 2 +- makefu/2configs/tools/sec.nix | 2 +- 6 files changed, 8 insertions(+), 6 deletions(-) diff --git a/makefu/2configs/task-client.nix b/makefu/2configs/task-client.nix index 330616f4a..470193d6c 100644 --- a/makefu/2configs/task-client.nix +++ b/makefu/2configs/task-client.nix @@ -1,6 +1,6 @@ { pkgs, ... }: { - krebs.per-user.makefu.packages = [ + users.users.makefu.packages = [ pkgs.taskwarrior ]; diff --git a/makefu/2configs/tools/core-gui.nix b/makefu/2configs/tools/core-gui.nix index 898bae10d..1e85da53c 100644 --- a/makefu/2configs/tools/core-gui.nix +++ b/makefu/2configs/tools/core-gui.nix @@ -1,10 +1,10 @@ { pkgs, ... }: { - krebs.per-user.makefu.packages = with pkgs; [ + users.users.makefu.packages = with pkgs; [ chromium - clipit feh + clipit firefox keepassx pcmanfm diff --git a/makefu/2configs/tools/desktop.nix b/makefu/2configs/tools/desktop.nix index 1fe03e111..bb14c3eb5 100644 --- a/makefu/2configs/tools/desktop.nix +++ b/makefu/2configs/tools/desktop.nix @@ -4,8 +4,10 @@ users.users.makefu.packages = with pkgs; [ taskwarrior pass + gopass mutt weechat tmux ]; + } diff --git a/makefu/2configs/tools/extra-gui.nix b/makefu/2configs/tools/extra-gui.nix index e25290297..ae97edd54 100644 --- a/makefu/2configs/tools/extra-gui.nix +++ b/makefu/2configs/tools/extra-gui.nix @@ -1,7 +1,7 @@ { pkgs, ... }: { - krebs.per-user.makefu.packages = with pkgs;[ + users.users.makefu.packages = with pkgs;[ # media gimp inkscape diff --git a/makefu/2configs/tools/media.nix b/makefu/2configs/tools/media.nix index 4de2b545e..35faaa29f 100644 --- a/makefu/2configs/tools/media.nix +++ b/makefu/2configs/tools/media.nix @@ -1,7 +1,7 @@ { pkgs, ... }: { - krebs.per-user.makefu.packages = with pkgs; [ + users.users.makefu.packages = with pkgs; [ kodi streamripper youtube-dl diff --git a/makefu/2configs/tools/sec.nix b/makefu/2configs/tools/sec.nix index 3dc02937d..17a980ef7 100644 --- a/makefu/2configs/tools/sec.nix +++ b/makefu/2configs/tools/sec.nix @@ -1,7 +1,7 @@ { pkgs, ... }: { - krebs.per-user.makefu.packages = with pkgs; [ + users.users.makefu.packages = with pkgs; [ aria2 # mitmproxy pythonPackages.binwalk-full -- cgit v1.2.3 From 0d129eca55cccfc062b784ceb42771e932225f35 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 16:28:17 +0200 Subject: ma nur: init --- makefu/2configs/nur.nix | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 makefu/2configs/nur.nix diff --git a/makefu/2configs/nur.nix b/makefu/2configs/nur.nix new file mode 100644 index 000000000..dda00063a --- /dev/null +++ b/makefu/2configs/nur.nix @@ -0,0 +1,7 @@ +{ pkgs, ... }:{ + nixpkgs.config.packageOverrides = pkgs: { + nur = pkgs.callPackage (import (builtins.fetchGit { + url = "https://github.com/nix-community/NUR"; + })) {}; + }; +} -- cgit v1.2.3 From b133bbe8ec5724c26249a5228b01e0ded368dec8 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 16:28:59 +0200 Subject: ma gold.krebsco.de: init config --- makefu/2configs/nginx/gold.krebsco.de.nix | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 makefu/2configs/nginx/gold.krebsco.de.nix diff --git a/makefu/2configs/nginx/gold.krebsco.de.nix b/makefu/2configs/nginx/gold.krebsco.de.nix new file mode 100644 index 000000000..083c0f8d7 --- /dev/null +++ b/makefu/2configs/nginx/gold.krebsco.de.nix @@ -0,0 +1,24 @@ +{ config, lib, pkgs, ... }: + +with import ; +let + gold = pkgs.fetchFromGitHub { + owner = "krebs"; + repo = "krebsgold"; + rev = "15f7a74"; + sha256= "1ya9xgg640k3hbl63022sfm44c1si2mxch8jkxindmwg4pa1y4ly"; + }; +in { + + services.nginx = { + enable = mkDefault true; + virtualHosts = { + "gold.krebsco.de" = { + enableACME = true; + forceSSL = true; + root = toString gold + "/html"; + }; + }; + }; +} + -- cgit v1.2.3 From a9211863965bc62de1628e9406da4fbd50f208d8 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 16:30:09 +0200 Subject: ma binary-cache/server: init --- makefu/2configs/binary-cache/server.nix | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 makefu/2configs/binary-cache/server.nix diff --git a/makefu/2configs/binary-cache/server.nix b/makefu/2configs/binary-cache/server.nix new file mode 100644 index 000000000..ad6256830 --- /dev/null +++ b/makefu/2configs/binary-cache/server.nix @@ -0,0 +1,31 @@ +{ config, lib, pkgs, ...}: + +{ + # generate private key with: + # nix-store --generate-binary-cache-key gum nix-serve.key nix-serve.pub + services.nix-serve = { + enable = true; + secretKeyFile = config.krebs.secret.files.nix-serve-key.path; + }; + + systemd.services.nix-serve = { + requires = ["secret.service"]; + after = ["secret.service"]; + }; + krebs.secret.files.nix-serve-key = { + path = "/run/secret/nix-serve.key"; + owner.name = "nix-serve"; + source-path = toString + "/nix-serve.key"; + }; + services.nginx = { + enable = true; + virtualHosts.nix-serve = { + serverAliases = [ "cache.gum.r" + "cache.euer.krebsco.de" + "cache.gum.krebsco.de" + ]; + locations."/".proxyPass= "http://localhost:${toString config.services.nix-serve.port}"; + }; + }; +} + -- cgit v1.2.3 From 5c7b8b6d0aa9589f9a6d0c353c0859e34a034488 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 16:31:04 +0200 Subject: nextgum.r: add extra hosts cache.gum, gold --- krebs/3modules/makefu/default.nix | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/krebs/3modules/makefu/default.nix b/krebs/3modules/makefu/default.nix index c5404f96d..9630d7a7f 100644 --- a/krebs/3modules/makefu/default.nix +++ b/krebs/3modules/makefu/default.nix @@ -336,7 +336,6 @@ with import ; "krebsco.de" = '' euer IN MX 1 aspmx.l.google.com. nixos.unstable IN CNAME krebscode.github.io. - gold IN A ${nets.internet.ip4.addr} boot IN A ${nets.internet.ip4.addr} ''; }; @@ -522,6 +521,13 @@ with import ; }; nextgum = rec { ci = true; + extraZones = { + "krebsco.de" = '' + cache.euer IN A ${nets.internet.ip4.addr} + cache.gum IN A ${nets.internet.ip4.addr} + gold IN A ${nets.internet.ip4.addr} + ''; + }; cores = 8; nets = rec { internet = { @@ -537,6 +543,7 @@ with import ; ip6.addr = "42:f9f0:0000:0000:0000:0000:0000:70d3"; aliases = [ "nextgum.r" + "cache.gum.r" ]; tinc.pubkey = '' -----BEGIN RSA PUBLIC KEY----- -- cgit v1.2.3 From d6054035fcddf9e6be555a898db72d0cba6102d5 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 16:31:43 +0200 Subject: k rtorrent: use directory.watch instead of schedule for inotify goodness --- krebs/3modules/rtorrent.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/krebs/3modules/rtorrent.nix b/krebs/3modules/rtorrent.nix index b7ef824b5..09e552010 100644 --- a/krebs/3modules/rtorrent.nix +++ b/krebs/3modules/rtorrent.nix @@ -29,7 +29,7 @@ let ''} ${optionalString (cfg.watchDir != null) '' - schedule = watch_directory,5,5,load_start=${cfg.watchDir}/*.torrent + directory.watch.added = "${cfg.watchDir}", load.start_verbose ''} directory = ${cfg.downloadDir} -- cgit v1.2.3 From a37455fd69b143cc0e7271b06fdd4fc0bef19c72 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 16:32:32 +0200 Subject: ma nextgum/hardware-config: add new logical devices --- makefu/1systems/nextgum/config.nix | 2 ++ makefu/1systems/nextgum/hardware-config.nix | 14 ++++++++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/makefu/1systems/nextgum/config.nix b/makefu/1systems/nextgum/config.nix index 93171d23a..21c33cf76 100644 --- a/makefu/1systems/nextgum/config.nix +++ b/makefu/1systems/nextgum/config.nix @@ -49,6 +49,7 @@ in { # + ## buildbot @@ -69,6 +70,7 @@ in { # # # + # # diff --git a/makefu/1systems/nextgum/hardware-config.nix b/makefu/1systems/nextgum/hardware-config.nix index 36fea6544..944210701 100644 --- a/makefu/1systems/nextgum/hardware-config.nix +++ b/makefu/1systems/nextgum/hardware-config.nix @@ -45,12 +45,20 @@ in { "ata_piix" "vmw_pvscsi" "virtio_pci" "sd_mod" "ahci" "xhci_pci" "ehci_pci" "ahci" "sd_mod" ]; - boot.kernelModules = [ "kvm-intel" ]; + boot.kernelModules = [ "kvm-intel" "dm-raid" "dm_thin_pool" ]; hardware.enableRedistributableFirmware = true; fileSystems."/" = { device = "/dev/mapper/nixos-root"; fsType = "ext4"; }; + fileSystems."/var/lib" = { + device = "/dev/mapper/nixos-lib"; + fsType = "ext4"; + }; + fileSystems."/var/download" = { + device = "/dev/mapper/nixos-download"; + fsType = "ext4"; + }; fileSystems."/boot" = { device = "/dev/sda2"; fsType = "vfat"; @@ -69,7 +77,9 @@ in { #pvcreate /dev/sda3 #pvcreate /dev/sdb1 #vgcreate nixos /dev/sda3 /dev/sdb1 - #lvcreate -L 120G -n root nixos + #lvcreate -L 120G -m 1 -n root nixos + #lvcreate -L 50G -m 1 -n lib nixos + #lvcreate -L 50G -n download nixos #mkfs.ext4 /dev/mapper/nixos-root #mount /dev/mapper/nixos-root /mnt #mkdir /mnt/boot -- cgit v1.2.3 From 3a2aa8310c2b4137f27de2b90b61bda48fcaa880 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 16:33:14 +0200 Subject: ma wbob.r: collect more stats --- makefu/1systems/wbob/config.nix | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/makefu/1systems/wbob/config.nix b/makefu/1systems/wbob/config.nix index 7c81a2015..c7301e52b 100644 --- a/makefu/1systems/wbob/config.nix +++ b/makefu/1systems/wbob/config.nix @@ -39,11 +39,15 @@ in { # Sensors - - - # + + + + + # + + (let -- cgit v1.2.3 From 44b0190c33b9276167ac699a825503c8e9866654 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 16:35:47 +0200 Subject: ma x.r: use nur --- makefu/1systems/x/config.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/makefu/1systems/x/config.nix b/makefu/1systems/x/config.nix index 451689f91..e5b481ab6 100644 --- a/makefu/1systems/x/config.nix +++ b/makefu/1systems/x/config.nix @@ -8,6 +8,7 @@ with import ; imports = [ # base + @@ -54,7 +55,6 @@ with import ; internalInterfaces = [ "vboxnet0" ]; }; } - # Services @@ -64,6 +64,7 @@ with import ; # Hardware + # # @@ -125,7 +126,7 @@ with import ; krebs.build.host = config.krebs.hosts.x; - krebs.tinc.retiolum.connectTo = [ "omo" "gum" "prism" ]; + krebs.tinc.retiolum.connectTo = [ "omo" "gum" "prism" "nextgum" ]; networking.extraHosts = '' 192.168.1.11 omo.local @@ -133,6 +134,8 @@ with import ; ''; # hard dependency because otherwise the device will not be unlocked boot.initrd.luks.devices = [ { name = "luksroot"; device = "/dev/sda2"; allowDiscards=true; }]; + # avoid full boot dir + boot.loader.grub.configurationLimit = 3; environment.systemPackages = [ pkgs.passwdqc-utils pkgs.nixUnstable ]; nixpkgs.overlays = [ (import ) ]; -- cgit v1.2.3 From e48a0723a9679408d88ff3b2452ff78fe407e33a Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 17:50:10 +0200 Subject: ma hw/stk1160: fix TODO --- makefu/2configs/hw/stk1160.nix | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/makefu/2configs/hw/stk1160.nix b/makefu/2configs/hw/stk1160.nix index 4ac639a25..735cb4c17 100644 --- a/makefu/2configs/hw/stk1160.nix +++ b/makefu/2configs/hw/stk1160.nix @@ -1,13 +1,12 @@ { pkgs, lib, ... }: { - # TODO: un-pin linuxPackages somehow - nixpkgs.config.packageOverrides = pkgs: { - linux_4_14 = pkgs.linux_4_14.override { - extraConfig = '' - MEDIA_ANALOG_TV_SUPPORT y - VIDEO_STK1160_COMMON m - VIDEO_STK1160 m - ''; - }; + boot.kernelPatches = lib.singleton { + name = "enable-stk1160"; + patch = null; + extraConfig = '' + MEDIA_ANALOG_TV_SUPPORT y + VIDEO_STK1160_COMMON m + VIDEO_STK1160 m + ''; }; } -- cgit v1.2.3 From c9e81b8dfd2c70495a415b472d0c5874db2a2700 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 17:51:29 +0200 Subject: ma hw/mceusb: use boot.kernelPatches --- makefu/2configs/hw/mceusb.nix | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/makefu/2configs/hw/mceusb.nix b/makefu/2configs/hw/mceusb.nix index c1d6f5651..069e6e7eb 100644 --- a/makefu/2configs/hw/mceusb.nix +++ b/makefu/2configs/hw/mceusb.nix @@ -1,4 +1,4 @@ -{pkgs,...}:{ +{pkgs, lib, ...}:{ # Disable the MCE remote from acting like a keyboard. (We use lirc instead.) services.xserver.inputClassSections = ['' Identifier "MCE USB Keyboard mimic blacklist" @@ -6,13 +6,12 @@ MatchProduct "Media Center Ed. eHome Infrared Remote Transceiver (1934:5168)" Option "Ignore" "on" '']; - boot.kernelPackages = builtins.trace "Using linux kernel 4.16, not latest" pkgs.linuxPackages_4_16; - nixpkgs.config.packageOverrides = pkgs: { - linux_4_16 = pkgs.linux_4_16.override { - extraConfig = '' - LIRC y - ''; - }; + boot.kernelPatches = lib.singleton { + name = "enable-lirc"; + patch = null; + extraConfig = '' + LIRC y + ''; }; } -- cgit v1.2.3 From 1b00f9ea1719db185e6659bd8502d0e1656d4244 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 17:52:20 +0200 Subject: ma hw/network-manager: enable wifi-options and remove sessionCommands --- makefu/2configs/hw/network-manager.nix | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/makefu/2configs/hw/network-manager.nix b/makefu/2configs/hw/network-manager.nix index d322c683d..ffc32e0cb 100644 --- a/makefu/2configs/hw/network-manager.nix +++ b/makefu/2configs/hw/network-manager.nix @@ -22,15 +22,9 @@ }; networking.networkmanager.enable = true; - # TODO: put somewhere else - services.xserver.displayManager.sessionCommands = '' - ${pkgs.clipit}/bin/clipit & - ${pkgs.networkmanagerapplet}/bin/nm-applet & - ''; - # nixOSUnstable -# networking.networkmanager.wifi = { -# powersave = true; -# scanRandMacAddress = true; -# }; + networking.networkmanager.wifi = { + powersave = true; + scanRandMacAddress = true; + }; } -- cgit v1.2.3 From b352a570c14026d32381f4313c97a0560d1c00d1 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 17:52:48 +0200 Subject: ma torrent: use base-dir instead of torrent-dir --- makefu/2configs/torrent.nix | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/makefu/2configs/torrent.nix b/makefu/2configs/torrent.nix index a076479c2..3df0ddbfe 100644 --- a/makefu/2configs/torrent.nix +++ b/makefu/2configs/torrent.nix @@ -8,13 +8,13 @@ let peer-port = 51412; web-port = 8112; daemon-port = 58846; - torrent-dir = config.makefu.dl-dir; + base-dir = config.makefu.dl-dir; in { users.users = { download = { name = "download"; - home = torrent-dir; + home = base-dir; uid = mkDefault (genid "download"); createHome = true; useDefaultShell = true; @@ -25,10 +25,12 @@ in { # todo: race condition, do this after download user has been created system.activationScripts."download-dir-chmod" = '' - for i in finished watch torrents; do - mkdir -p "${torrent-dir}/$i" - chown download:download "${torrent-dir}/$i" - chmod 770 "${torrent-dir}/$i" + for i in finished watch; do + if test ! -d $i;then + mkdir -p "${base-dir}/$i" + chown rtorrent:download "${base-dir}/$i" + chmod 775 "${base-dir}/$i" + fi done ''; @@ -42,6 +44,7 @@ in { "nginx" ]; }; + rtorrent.members = [ "download" ]; }; krebs.rtorrent = { @@ -54,7 +57,8 @@ in { rutorrent.enable = true; enableXMLRPC = true; listenPort = peer-port; - workDir = torrent-dir; + downloadDir = base-dir + "/finished"; + watchDir = base-dir + "/watch"; # dump old torrents into watch folder to have them re-added }; -- cgit v1.2.3 From 3991beae129cd5da65dc83360691b3a34a16ba25 Mon Sep 17 00:00:00 2001 From: makefu Date: Mon, 6 Aug 2018 17:53:56 +0200 Subject: ma pkgs.awesomecfg.full: start networkmanager,blueman-applet,clipit --- makefu/5pkgs/awesomecfg/default.nix | 7 +++++-- makefu/5pkgs/awesomecfg/full.cfg | 14 +++++++++++++- 2 files changed, 18 insertions(+), 3 deletions(-) diff --git a/makefu/5pkgs/awesomecfg/default.nix b/makefu/5pkgs/awesomecfg/default.nix index e5f62e910..486c0ddf6 100644 --- a/makefu/5pkgs/awesomecfg/default.nix +++ b/makefu/5pkgs/awesomecfg/default.nix @@ -2,7 +2,10 @@ , lib , alsaUtils , xbacklight -, modkey?"Mod4" +, networkmanagerapplet +, blueman +, clipit +, modkey ? "Mod4" , locker? "${pkgs.xlock}/bin/xlock -mode blank" , ... }: @@ -10,7 +13,7 @@ # replace: @alsaUtils@ @xlockmore@ @xbacklight@ @modkey@ full = lib.makeOverridable pkgs.substituteAll { name = "awesome_full_config"; - inherit alsaUtils locker xbacklight modkey; + inherit alsaUtils locker xbacklight modkey networkmanagerapplet blueman clipit; isExecutable = false; src = ./full.cfg; }; diff --git a/makefu/5pkgs/awesomecfg/full.cfg b/makefu/5pkgs/awesomecfg/full.cfg index e49a88697..12d357913 100644 --- a/makefu/5pkgs/awesomecfg/full.cfg +++ b/makefu/5pkgs/awesomecfg/full.cfg @@ -568,6 +568,18 @@ local os = { -- }}} - +-- {{{ autostart +do + local cmds = + { + "@networkmanagerapplet@/bin/nm-applet", + "@blueman@/bin/blueman-applet", + "@clipit@/bin/clipit" + } + + for _,i in pairs(cmds) do + awful.util.spawn(i) + end +end -- }}} -- cgit v1.2.3 From b04524ae20dd63dc5c7a1c896ce8b89d52197bc1 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 8 Aug 2018 10:22:04 +0200 Subject: ma nextgum.r: add events-publisher --- makefu/1systems/nextgum/config.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/makefu/1systems/nextgum/config.nix b/makefu/1systems/nextgum/config.nix index 21c33cf76..9761546e7 100644 --- a/makefu/1systems/nextgum/config.nix +++ b/makefu/1systems/nextgum/config.nix @@ -71,6 +71,7 @@ in { # # + # # -- cgit v1.2.3 From 6368507f02eb4e267c7fdab73e4c3cec5ee5827f Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 8 Aug 2018 21:11:41 +0200 Subject: ma events-publisher: init --- .../deployment/events-publisher/default.nix | 48 ++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 makefu/2configs/deployment/events-publisher/default.nix diff --git a/makefu/2configs/deployment/events-publisher/default.nix b/makefu/2configs/deployment/events-publisher/default.nix new file mode 100644 index 000000000..db8502c6e --- /dev/null +++ b/makefu/2configs/deployment/events-publisher/default.nix @@ -0,0 +1,48 @@ +{ pkgs, ... }: +with import ; +let + shack-announce = pkgs.callPackage (builtins.fetchTarball { + url = "https://github.com/makefu/events-publisher/archive/15fbe5cc6ac9617a08a042870795f9e879d9952a.tar.gz"; + sha256 = "1bqp1qdnwx5q1w468zbm57hmpjz3x8if3j29qrqcia0vzks1s37a"; + }) {} ; + home = "/var/lib/shackannounce"; + user = "shackannounce"; + creds = (toString ) + "/shack-announce.json"; +in +{ + users.users.${user}= { + uid = genid user; + inherit home; + createHome = true; + }; + systemd.services.shack-announce = { + description = "Announce shack events"; + startAt = "*:0/30"; + path = [ shack-announce ]; + serviceConfig = { + WorkingDirectory = home; + User = user; + PermissionsStartOnly = true; + ExecStartPre = pkgs.writeDash "shack-announce-pre" '' + set -eu + cp ${creds} creds.json + chown ${user} creds.json + ''; + ExecStart = pkgs.writeDash "shack-announce" '' + if test ! -e announce.state; then + echo "initializing state" + announce-daemon \ + --lol INFO \ + --creds creds.json \ + --state announce.state \ + --clean --init + fi + echo "Running announce" + announce-daemon \ + --lol INFO \ + --creds creds.json \ + --state announce.state + ''; + }; + }; +} -- cgit v1.2.3 From f9d96d13de74ed6acbde92778af88f94f04081bd Mon Sep 17 00:00:00 2001 From: lassulus Date: Thu, 9 Aug 2018 14:38:06 +0200 Subject: genid_signed -> genid_uint31 --- lass/2configs/browsers.nix | 2 +- lass/2configs/ciko.nix | 2 +- lass/2configs/websites/domsen.nix | 18 +++++++++--------- lass/3modules/xjail.nix | 2 +- lib/default.nix | 2 +- 5 files changed, 13 insertions(+), 13 deletions(-) diff --git a/lass/2configs/browsers.nix b/lass/2configs/browsers.nix index 64fa6573a..425e0ee13 100644 --- a/lass/2configs/browsers.nix +++ b/lass/2configs/browsers.nix @@ -29,7 +29,7 @@ let environment.systemPackages = [ config.lass.xjail-bins.${name} (pkgs.writeDashBin "cx-${name}" '' - DISPLAY=:${toString (genid_signed name)} ${pkgs.xclip}/bin/xclip -o | DISPLAY=:0 ${pkgs.xclip}/bin/xclip + DISPLAY=:${toString (genid_uint31 name)} ${pkgs.xclip}/bin/xclip