summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjeschli <jeschli@gmail.com>2019-01-29 19:17:43 +0100
committerjeschli <jeschli@gmail.com>2019-01-29 19:17:43 +0100
commit924c8fb748a92720c75750cee528ac2f4b7c5c8e (patch)
tree1a3b956f7f8527e533040cee1138810fe304bbc9
parent06b6454af78e8236a67d69cab94f62c32054be47 (diff)
parente64bbd8d6864e21f9e7b6b9a11cf95c976bdc109 (diff)
Merge branch 'master' of prism.r:stockholm
-rw-r--r--ci.nix2
-rw-r--r--krebs/1systems/hotdog/config.nix4
-rw-r--r--krebs/1systems/wolf/config.nix1
-rw-r--r--krebs/2configs/exim-smarthost.nix50
-rw-r--r--krebs/2configs/nscd-fix.nix24
-rw-r--r--krebs/2configs/reaktor-krebs.nix30
-rw-r--r--krebs/2configs/reaktor-retiolum.nix21
-rw-r--r--krebs/2configs/reaktor2.nix152
-rw-r--r--krebs/2configs/shack/mobile.mpd.nix5
-rw-r--r--krebs/2configs/shack/ympd-top-next.patch16
-rw-r--r--krebs/3modules/Reaktor.nix5
-rw-r--r--krebs/3modules/default.nix145
-rw-r--r--krebs/3modules/dns.nix12
-rw-r--r--krebs/3modules/external/default.nix53
-rw-r--r--krebs/3modules/github-known-hosts.nix40
-rw-r--r--krebs/3modules/hosts.nix35
-rw-r--r--krebs/3modules/per-user.nix2
-rw-r--r--krebs/3modules/reaktor2.nix71
-rw-r--r--krebs/3modules/retiolum-hosts.nix28
-rw-r--r--krebs/3modules/tinc.nix1
-rw-r--r--krebs/5pkgs/default.nix2
-rw-r--r--krebs/5pkgs/haskell/blessings.nix4
-rw-r--r--krebs/5pkgs/haskell/much.nix (renamed from krebs/5pkgs/simple/much/cabal.nix)9
-rw-r--r--krebs/5pkgs/haskell/reaktor2.nix27
-rw-r--r--krebs/5pkgs/simple/Reaktor/default.nix6
-rw-r--r--krebs/5pkgs/simple/Reaktor/plugins.nix68
-rwxr-xr-x[-rw-r--r--]krebs/5pkgs/simple/Reaktor/scripts/random-emoji.sh2
-rwxr-xr-x[-rw-r--r--]krebs/5pkgs/simple/Reaktor/scripts/random-issue.sh0
-rwxr-xr-x[-rw-r--r--]krebs/5pkgs/simple/Reaktor/scripts/sed-plugin.py2
-rwxr-xr-x[-rw-r--r--]krebs/5pkgs/simple/Reaktor/scripts/shack-correct.sh0
-rw-r--r--krebs/5pkgs/simple/much/default.nix3
-rw-r--r--krebs/5pkgs/simple/reaktor2-plugins.nix106
-rw-r--r--krebs/krops.nix20
-rw-r--r--krebs/nixpkgs.json6
-rw-r--r--lass/1systems/blue/source.nix17
-rw-r--r--lass/1systems/mors/config.nix2
-rw-r--r--lass/1systems/prism/config.nix15
-rw-r--r--lass/1systems/prism/physical.nix24
-rw-r--r--lass/1systems/yellow/config.nix92
-rw-r--r--lass/2configs/baseX.nix4
-rw-r--r--lass/2configs/default.nix6
-rw-r--r--lass/2configs/exim-smarthost.nix1
-rw-r--r--lass/2configs/games.nix1
-rw-r--r--lass/2configs/gc.nix2
-rw-r--r--lass/2configs/hardening.nix11
-rw-r--r--lass/2configs/mail.nix4
-rw-r--r--lass/2configs/radio.nix61
-rw-r--r--lass/2configs/reaktor-coders.nix180
-rw-r--r--lass/2configs/websites/domsen.nix38
-rw-r--r--lass/2configs/websites/lassulus.nix3
-rw-r--r--lass/3modules/default.nix1
-rw-r--r--lass/3modules/xserver/default.nix103
-rw-r--r--lass/3modules/xserver/xserver.conf.nix40
-rw-r--r--lass/5pkgs/custom/xmonad-lass/default.nix3
-rw-r--r--makefu/0tests/data/secrets/nixos-community0
-rw-r--r--makefu/1systems/cake/config.nix38
-rw-r--r--makefu/1systems/cake/hardware-config.nix42
-rw-r--r--makefu/1systems/gum/config.nix5
-rw-r--r--makefu/1systems/gum/hardware-config.nix2
-rw-r--r--makefu/1systems/gum/source.nix1
-rw-r--r--makefu/1systems/x/config.nix5
-rw-r--r--makefu/2configs/bgt/download.binaergewitter.de.nix30
-rw-r--r--makefu/2configs/bureautomation/default.nix7
-rw-r--r--makefu/2configs/bureautomation/hass.nix112
-rw-r--r--makefu/2configs/default.nix3
-rw-r--r--makefu/2configs/deployment/owncloud.nix1
-rw-r--r--makefu/2configs/dict.nix5
-rw-r--r--makefu/2configs/gui/base.nix1
-rw-r--r--makefu/2configs/home-manager/cli.nix30
-rw-r--r--makefu/2configs/home-manager/desktop.nix9
-rw-r--r--makefu/2configs/home-manager/zsh.nix126
-rw-r--r--makefu/2configs/hw/malduino_elite.nix15
-rw-r--r--makefu/2configs/printer.nix3
-rw-r--r--makefu/2configs/remote-build/aarch64-community.nix15
-rw-r--r--makefu/2configs/tools/android-pentest.nix1
-rw-r--r--makefu/2configs/tools/dev.nix2
-rw-r--r--makefu/2configs/virtualisation/virtualbox.nix5
-rw-r--r--makefu/2configs/zsh-user.nix82
-rw-r--r--makefu/5pkgs/baidudl/default.nix23
-rw-r--r--makefu/5pkgs/default.nix10
-rw-r--r--makefu/krops.nix16
-rw-r--r--makefu/nixpkgs.json6
m---------submodules/krops0
-rw-r--r--tv/1systems/xu/config.nix6
-rw-r--r--tv/2configs/backup.nix4
-rw-r--r--tv/2configs/default.nix1
-rw-r--r--tv/2configs/gitrepos.nix3
-rw-r--r--tv/2configs/htop.nix2
-rw-r--r--tv/2configs/mail-client.nix17
-rw-r--r--tv/2configs/xserver/Xmodmap.nix1
-rw-r--r--tv/2configs/xserver/xkiller.nix14
-rw-r--r--tv/3modules/default.nix1
-rw-r--r--tv/3modules/ejabberd/default.nix2
-rw-r--r--tv/3modules/nixpkgs-overlays.nix23
-rw-r--r--tv/3modules/slock.nix20
-rw-r--r--tv/5pkgs/default.nix6
-rw-r--r--tv/5pkgs/simple/q/default.nix61
-rw-r--r--tv/5pkgs/simple/xkiller.nix25
98 files changed, 1507 insertions, 834 deletions
diff --git a/ci.nix b/ci.nix
index a383a0631..16c866e76 100644
--- a/ci.nix
+++ b/ci.nix
@@ -16,6 +16,6 @@ let
ci-systems = filterAttrs (_: v: v.ci) system.config.krebs.hosts;
build = host: owner:
- ((import (toString ./. + "/${owner}/krops.nix") { name = host; }).test {target = "${getEnv "HOME"}/stockholm-tmp";});
+ ((import (toString ./. + "/${owner}/krops.nix") { name = host; }).test {target = "${getEnv "HOME"}/stockholm-build";});
in mapAttrs (n: h: build n h.owner.name) ci-systems
diff --git a/krebs/1systems/hotdog/config.nix b/krebs/1systems/hotdog/config.nix
index cf72e0d73..916073375 100644
--- a/krebs/1systems/hotdog/config.nix
+++ b/krebs/1systems/hotdog/config.nix
@@ -12,8 +12,8 @@
<stockholm/krebs/2configs/buildbot-stockholm.nix>
<stockholm/krebs/2configs/binary-cache/nixos.nix>
<stockholm/krebs/2configs/ircd.nix>
- <stockholm/krebs/2configs/reaktor-retiolum.nix>
- <stockholm/krebs/2configs/reaktor-krebs.nix>
+ <stockholm/krebs/2configs/nscd-fix.nix>
+ <stockholm/krebs/2configs/reaktor2.nix>
<stockholm/krebs/2configs/repo-sync.nix>
];
diff --git a/krebs/1systems/wolf/config.nix b/krebs/1systems/wolf/config.nix
index 914b38051..ec8830711 100644
--- a/krebs/1systems/wolf/config.nix
+++ b/krebs/1systems/wolf/config.nix
@@ -161,6 +161,7 @@ in
users.extraUsers.root.openssh.authorizedKeys.keys = [
config.krebs.users.ulrich.pubkey
+ config.krebs.users.raute.pubkey
config.krebs.users.makefu-omo.pubkey
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAEAQDb9NPa2Hf51afcG1H13UPbE5E02J8aC9a1sGCRls592wAVlQbmojYR1jWDPA2m32Bsyv0ztqi81zDyndWWZPQVJVBk00VjYBcgk6D5ifqoAuWLzfuHJPWZGOvBf/U74/LNFNUkj1ywjneK7HYTRPXrRBBfBSQNmQzkvue7s599L2vdueZKyjNsMpx2m6nm2SchaMuDskSQut/168JgU1l4M8BeT68Bo4WdelhBYnhSI1a59FGkgdu2SCjyighLQRy2sOH3ksnkHWENPkA+wwQOlKl7R3DsEybrNd4NU9FSwFDyDmdhfv5gJp8UGSFdjAwx43+8zM5t5ruZ25J0LnVb0PuTuRA00UsW83MkLxFpDQLrQV08tlsY6iGrqxP67C3VJ6t4v6oTp7/vaRLhEFc1PhOLh+sZ18o8MLO+e2rGmHGHQnSKfBOLUvDMGa4jb01XBGjdnIXLOkVo79YR5jZn7jJb2gTZ95OD6bWSDADoURSuwuLa7kh4ti1ItAKuhkIvbuky3rRVvQEc92kJ6aNUswIUXJa0K2ibbIY6ycKAA3Ljksl3Mm9KzOn6yc/i/lSF+SOrTGhabPJigKkIoqKIwnV5IU3gkfsxPQJOBMPqHDGAOeYQe3WpWedEPYuhQEczw4exMb9TkNE96F71PzuQPJDl5sPAWyPLeMKpy5XbfRiF2by4nxN3ZIQvjtoyVkjNV+qM0q0yKBzLxuRAEQOZ2yCEaBudZQkQiwHD97H2vu4SRQ/2aOie1XiOnmdbQRDZSO3BsoDK569K1w+gDfSnqY7zVUMj6tw+uKx6Gstck5lbvYMtdWKsfPv/pDM8eyIVFLL93dKTX+ertcQj6xDwLfOiNubE5ayFXhYkjwImV6NgfBuq+3hLK0URP2rPlOZbbZTQ0WlKD6CCRZPMSZCU9oD2zYfqpvRArBUcdkAwGePezORkfJQLE6mYEJp6pdFkJ/IeFLbO6M0lZVlfnpzAC9kjjkMCRofZUETcFSppyTImCbgo3+ok59/PkNU5oavBXyW80ue2tWHr08HX/QALNte3UITmIIlU6SFMCPMWJqadK1eDPWfJ4H4iDXRNn3D5wqN++iMloKvpaj0wieqXLY4+YfvNTNr177OU48GEWW8DnoEkbpwsCbjPxznGDQhdDqdYyMY/fDgRQReKITvKYGHRzesGysw5cKsp9LEfXD0R6WE2TeiiENla5AWzTgXJB0AyZEcOiIfqOgT9Nr9S8q5gc/BdA7P+jhGGJgEHhV3dVlfIZ7pmZc27Yu7UTQ0lbAKWqcMSTOdne+QL6ILzbvLrQwdvax4tQdm5opfU16SrOox1AMwAbkdq84z6uJqYVx3cUXfMJgTyDNrVv3or root@plattenschwein" # for backup
];
diff --git a/krebs/2configs/exim-smarthost.nix b/krebs/2configs/exim-smarthost.nix
new file mode 100644
index 000000000..5dc24f1de
--- /dev/null
+++ b/krebs/2configs/exim-smarthost.nix
@@ -0,0 +1,50 @@
+with import <stockholm/lib>;
+{ config, ... }: let
+
+ format = from: to: {
+ inherit from;
+ # TODO assert is-retiolum-mail-address to;
+ to = concatMapStringsSep "," (getAttr "mail") (toList to);
+ };
+
+in {
+ krebs.exim-smarthost.internet-aliases =
+ mapAttrsToList format (with config.krebs.users; let
+ brain-ml = [
+ lass
+ makefu
+ tv
+ ];
+ eloop-ml = spam-ml ++ [ ciko ];
+ spam-ml = [
+ lass
+ makefu
+ tv
+ ];
+ ciko.mail = "ciko@slash16.net";
+ in {
+ "anmeldung@eloop.org" = eloop-ml;
+ "brain@krebsco.de" = brain-ml;
+ "cfp@eloop.org" = eloop-ml;
+ "kontakt@eloop.org" = eloop-ml;
+ "root@eloop.org" = eloop-ml;
+ "youtube@eloop.org" = eloop-ml;
+ "eloop2016@krebsco.de" = eloop-ml;
+ "eloop2017@krebsco.de" = eloop-ml;
+ "postmaster@krebsco.de" = spam-ml; # RFC 822
+ "lass@krebsco.de" = lass;
+ "makefu@krebsco.de" = makefu;
+ "spam@krebsco.de" = spam-ml;
+ "tv@krebsco.de" = tv;
+ # XXX These are no internet aliases
+ # XXX exim-retiolum hosts should be able to relay to retiolum addresses
+ "lass@retiolum" = lass;
+ "makefu@retiolum" = makefu;
+ "spam@retiolum" = spam-ml;
+ "tv@retiolum" = tv;
+ "lass@r" = lass;
+ "makefu@r" = makefu;
+ "spam@r" = spam-ml;
+ "tv@r" = tv;
+ });
+}
diff --git a/krebs/2configs/nscd-fix.nix b/krebs/2configs/nscd-fix.nix
new file mode 100644
index 000000000..8e5909e72
--- /dev/null
+++ b/krebs/2configs/nscd-fix.nix
@@ -0,0 +1,24 @@
+with import <stockholm/lib>;
+{ pkgs, ... }: let
+
+ enable = versionOlderThan "19.03";
+
+ versionOlderThan = v:
+ compareVersions
+ (versions.majorMinor version)
+ (versions.majorMinor v)
+ == -1;
+
+ warning = ''
+ Using custom services.nscd.config because
+ https://github.com/NixOS/nixpkgs/pull/50316
+ '';
+
+in
+ optionalAttrs enable (trace warning {
+ services.nscd.enable = mkForce true;
+ services.nscd.config = mkForce (readFile (pkgs.fetchurl {
+ url = https://raw.githubusercontent.com/arianvp/nixpkgs/1d5f4cb/nixos/modules/services/system/nscd.conf;
+ sha256 = "1jlddk38lyynjn51zx3xi1nc29ahajyh0qg48qbq6dqlsrn3wxqs";
+ }));
+ })
diff --git a/krebs/2configs/reaktor-krebs.nix b/krebs/2configs/reaktor-krebs.nix
deleted file mode 100644
index dc2838cae..000000000
--- a/krebs/2configs/reaktor-krebs.nix
+++ /dev/null
@@ -1,30 +0,0 @@
-{ config, lib, pkgs, ... }:
-with import <stockholm/lib>;
-
-{
- krebs.Reaktor.krebs = {
- nickname = "Reaktor|krebs";
- channels = [
- "#krebs"
- "#nixos-wiki"
- ];
- extraEnviron = {
- REAKTOR_HOST = "irc.freenode.org";
- REAKTOR_NICKSERV_PASSWORD = "/var/lib/Reaktor/reaktor_nickserv_password";
- };
- plugins = with pkgs.ReaktorPlugins; [
- sed-plugin
- task-add
- task-delete
- task-done
- task-list
- ] ++
- (attrValues (todo "agenda"))
- ;
- };
- krebs.secret.files.nix-serve-key = {
- path = "/var/lib/Reaktor/reaktor_nickserv_password";
- owner.name = "Reaktor";
- source-path = toString <secrets> + "/reaktor_nickserv_password";
- };
-}
diff --git a/krebs/2configs/reaktor-retiolum.nix b/krebs/2configs/reaktor-retiolum.nix
deleted file mode 100644
index 824f59d09..000000000
--- a/krebs/2configs/reaktor-retiolum.nix
+++ /dev/null
@@ -1,21 +0,0 @@
-{ config, lib, pkgs, ... }:
-with import <stockholm/lib>;
-
-{
- krebs.Reaktor.retiolum = {
- nickname = "Reaktor|lass";
- channels = [ "#noise" "#xxx" ];
- extraEnviron = {
- REAKTOR_HOST = "irc.r";
- };
- plugins = with pkgs.ReaktorPlugins; [
- sed-plugin
- task-add
- task-delete
- task-done
- task-list
- ] ++
- (attrValues (todo "agenda"))
- ;
- };
-}
diff --git a/krebs/2configs/reaktor2.nix b/krebs/2configs/reaktor2.nix
new file mode 100644
index 000000000..ff6b539ba
--- /dev/null
+++ b/krebs/2configs/reaktor2.nix
@@ -0,0 +1,152 @@
+with import <stockholm/lib>;
+{ config, pkgs, ... }:
+
+let
+ #for shared state directory
+ stateDir = config.krebs.reaktor2.r.stateDir;
+
+ generators = pkgs.reaktor2-plugins.generators;
+ hooks = pkgs.reaktor2-plugins.hooks;
+ commands = pkgs.reaktor2-plugins.commands;
+
+ task = name: let
+ rcFile = builtins.toFile "taskrc" ''
+ confirmation=no
+ '';
+ in {
+ pattern = "^${name}-([a-z]+)(?::\\s*(.*))?";
+ activate = "match";
+ command = 1;
+ arguments = [2];
+ env.TASKDATA = "${stateDir}/${name}";
+ commands = {
+ add.filename = pkgs.writeDash "${name}-task-add" ''
+ ${pkgs.taskwarrior}/bin/task rc:${rcFile} add "$1"
+ '';
+ list.filename = pkgs.writeDash "${name}-task-list" ''
+ ${pkgs.taskwarrior}/bin/task rc:${rcFile} export \
+ | ${pkgs.jq}/bin/jq -r '
+ .[] | select(.id != 0) | "\(.id) \(.description)"
+ '
+ '';
+ delete.filename = pkgs.writeDash "${name}-task-delete" ''
+ ${pkgs.taskwarrior}/bin/task rc:${rcFile} delete "$1"
+ '';
+ done.filename = pkgs.writeDash "${name}-task-done" ''
+ ${pkgs.taskwarrior}/bin/task rc:${rcFile} done "$1"
+ '';
+ };
+ };
+
+ systemPlugin = {
+ plugin = "system";
+ config = {
+ workdir = stateDir;
+ hooks.JOIN = [
+ {
+ activate = "always";
+ command = {
+ filename =
+ "${pkgs.Reaktor.src}/reaktor/commands/tell-on_join";
+ env = {
+ PATH = makeBinPath [
+ pkgs.coreutils # XXX env, touch
+ pkgs.jq # XXX sed
+ pkgs.utillinux # XXX flock
+ ];
+ state_file = "${stateDir}/tell.json";
+ };
+ };
+ }
+ ];
+ hooks.PRIVMSG = [
+ {
+ pattern = "^bier bal(ance)*$";
+ activate = "match";
+ command = {
+ env = {
+