diff options
Diffstat (limited to 'makefu')
-rw-r--r-- | makefu/0tests/data/secrets/id_nixBuild | 0 | ||||
-rw-r--r-- | makefu/1systems/cake/config.nix | 13 | ||||
-rw-r--r-- | makefu/1systems/gum/config.nix | 1 | ||||
-rw-r--r-- | makefu/1systems/gum/hardware-config.nix | 18 | ||||
-rw-r--r-- | makefu/1systems/x/config.nix | 28 | ||||
-rw-r--r-- | makefu/2configs/dict.nix | 1 | ||||
-rw-r--r-- | makefu/2configs/git/cgit-retiolum.nix | 9 | ||||
-rw-r--r-- | makefu/2configs/home-manager/desktop.nix | 9 | ||||
-rw-r--r-- | makefu/2configs/home-manager/zsh.nix | 3 | ||||
-rw-r--r-- | makefu/2configs/homeautomation/default.nix | 4 | ||||
-rw-r--r-- | makefu/2configs/homeautomation/google-muell.nix | 15 | ||||
-rw-r--r-- | makefu/2configs/remote-build/gum.nix | 15 | ||||
-rw-r--r-- | makefu/2configs/remote-build/slave.nix | 1 | ||||
-rw-r--r-- | makefu/2configs/tools/core-gui.nix | 1 | ||||
-rw-r--r-- | makefu/2configs/tools/core.nix | 2 | ||||
-rw-r--r-- | makefu/2configs/tools/games.nix | 2 | ||||
-rw-r--r-- | makefu/5pkgs/ampel/default.nix | 6 | ||||
-rw-r--r-- | makefu/5pkgs/awesomecfg/default.nix | 3 | ||||
-rw-r--r-- | makefu/5pkgs/awesomecfg/full.cfg | 1 | ||||
-rw-r--r-- | makefu/nixpkgs.json | 6 |
20 files changed, 102 insertions, 36 deletions
diff --git a/makefu/0tests/data/secrets/id_nixBuild b/makefu/0tests/data/secrets/id_nixBuild new file mode 100644 index 000000000..e69de29bb --- /dev/null +++ b/makefu/0tests/data/secrets/id_nixBuild diff --git a/makefu/1systems/cake/config.nix b/makefu/1systems/cake/config.nix index e40042b2d..8617578f0 100644 --- a/makefu/1systems/cake/config.nix +++ b/makefu/1systems/cake/config.nix @@ -1,9 +1,16 @@ { config, lib, pkgs, ... }: -{ +let + primaryInterface = "eth0"; +in { imports = [ <stockholm/makefu> ./hardware-config.nix - <stockholm/makefu/2configs/tools/core.nix> + # <stockholm/makefu/2configs/tools/core.nix> + { environment.systemPackages = with pkgs;[ rsync screen curl git ];} + <stockholm/makefu/2configs/binary-cache/nixos.nix> + #<stockholm/makefu/2configs/support-nixos.nix> + <stockholm/makefu/2configs/homeautomation/default.nix> + <stockholm/makefu/2configs/homeautomation/google-muell.nix> # configure your hw: # <stockholm/makefu/2configs/save-diskspace.nix> ]; @@ -12,7 +19,7 @@ tinc.retiolum.enable = true; build.host = config.krebs.hosts.cake; }; - + networking.firewall.trustedInterfaces = [ primaryInterface ]; documentation.info.enable = false; documentation.man.enable = false; services.nixosManual.enable = false; diff --git a/makefu/1systems/gum/config.nix b/makefu/1systems/gum/config.nix index e274b4bf8..7bc06f833 100644 --- a/makefu/1systems/gum/config.nix +++ b/makefu/1systems/gum/config.nix @@ -84,6 +84,7 @@ in { <stockholm/makefu/2configs/shack/events-publisher> <stockholm/makefu/2configs/shack/gitlab-runner> <stockholm/makefu/2configs/remote-build/slave.nix> + <stockholm/makefu/2configs/remote-build/aarch64-community.nix> <stockholm/makefu/2configs/taskd.nix> # services diff --git a/makefu/1systems/gum/hardware-config.nix b/makefu/1systems/gum/hardware-config.nix index 542b79fe7..857fad7aa 100644 --- a/makefu/1systems/gum/hardware-config.nix +++ b/makefu/1systems/gum/hardware-config.nix @@ -41,36 +41,36 @@ in { boot.loader.grub.enable = true; boot.loader.grub.version = 2; boot.loader.grub.devices = [ main-disk ]; - boot.initrd.kernelModules = [ "dm-raid" ]; + boot.initrd.kernelModules = [ "dm-raid" "dm_cache" ]; boot.initrd.availableKernelModules = [ "ata_piix" "vmw_pvscsi" "virtio_pci" "sd_mod" "ahci" "xhci_pci" "ehci_pci" "ahci" "sd_mod" ]; - boot.kernelModules = [ "dm-thin-pool" "kvm-intel" ]; + boot.kernelModules = [ "dm-raid" "dm_cache" "dm-thin-pool" "kvm-intel" ]; hardware.enableRedistributableFirmware = true; fileSystems."/" = { - device = "/dev/mapper/nixos-root"; + device = "/dev/nixos/root"; fsType = "ext4"; }; fileSystems."/var/lib" = { - device = "/dev/mapper/nixos-lib"; + device = "/dev/nixos/lib"; fsType = "ext4"; }; fileSystems."/var/log" = { - device = "/dev/mapper/nixos-log"; + device = "/dev/nixos/log"; fsType = "ext4"; }; fileSystems."/var/download" = { - device = "/dev/mapper/nixos-download"; + device = "/dev/nixos/download"; fsType = "ext4"; }; fileSystems."/var/www/binaergewitter" = { - device = "/dev/mapper/nixos-binaergewitter"; + device = "/dev/nixos/binaergewitter"; fsType = "ext4"; - options = [ "nofail" ]; + options = [ "nofail" "x-systemd.automount" "x-systemd.device-timeout=5s" "x-systemd.mount-timeout=5s" ]; }; fileSystems."/var/lib/borgbackup" = { - device = "/dev/mapper/nixos-backup"; + device = "/dev/nixos/backup"; fsType = "ext4"; }; fileSystems."/boot" = { diff --git a/makefu/1systems/x/config.nix b/makefu/1systems/x/config.nix index 138735d91..ceeccc0b2 100644 --- a/makefu/1systems/x/config.nix +++ b/makefu/1systems/x/config.nix @@ -15,6 +15,13 @@ <stockholm/makefu/2configs/extra-fonts.nix> <stockholm/makefu/2configs/tools/all.nix> <stockholm/makefu/2configs/dict.nix> + #<stockholm/makefu/3modules/netboot_server.nix> + #{ + # netboot_server = { + # network.wan = "wlp3s0"; + # network.lan = "enp0s25"; + # }; + #} <stockholm/makefu/2configs/backup/state.nix> # <stockholm/makefu/2configs/dnscrypt/client.nix> @@ -52,21 +59,23 @@ # Virtualization <stockholm/makefu/2configs/virtualisation/libvirt.nix> <stockholm/makefu/2configs/virtualisation/docker.nix> - <stockholm/makefu/2configs/virtualisation/virtualbox.nix> - { - networking.firewall.allowedTCPPorts = [ 8080 ]; - networking.nat = { - enable = true; - externalInterface = "wlp3s0"; - internalInterfaces = [ "vboxnet0" ]; - }; - } + # <stockholm/makefu/2configs/virtualisation/virtualbox.nix> + #{ + # networking.firewall.allowedTCPPorts = [ 8080 ]; + # networking.nat = { + # enable = true; + # externalInterface = "wlp3s0"; + # internalInterfaces = [ "vboxnet0" ]; + # }; + #} # Services <stockholm/makefu/2configs/git/brain-retiolum.nix> <stockholm/makefu/2configs/tor.nix> <stockholm/makefu/2configs/vpn/vpngate.nix> # <stockholm/makefu/2configs/buildbot-standalone.nix> <stockholm/makefu/2configs/remote-build/aarch64-community.nix> + <stockholm/makefu/2configs/remote-build/gum.nix> + { nixpkgs.overlays = [ (self: super: super.prefer-remote-fetch self super) ]; } # Hardware <stockholm/makefu/2configs/hw/tp-x230.nix> @@ -162,7 +171,6 @@ "/home/makefu/docs" "/home/makefu/.password-store" "/home/makefu/.secrets-pass" - "/home/makefu/autosync/Database.kdb" ]; services.syncthing.user = lib.mkForce "makefu"; diff --git a/makefu/2configs/dict.nix b/makefu/2configs/dict.nix index 6db9102ba..08f1f8502 100644 --- a/makefu/2configs/dict.nix +++ b/makefu/2configs/dict.nix @@ -1,5 +1,6 @@ { pkgs, ... }: { + environment.shellAliases.dict = "dict -h 127.0.0.1"; services.dictd.enable = true; services.dictd.DBs = with pkgs.dictdDBs; [ wiktionary wordnet deu2eng eng2deu ]; } diff --git a/makefu/2configs/git/cgit-retiolum.nix b/makefu/2configs/git/cgit-retiolum.nix index 4890e4afe..0ff855980 100644 --- a/makefu/2configs/git/cgit-retiolum.nix +++ b/makefu/2configs/git/cgit-retiolum.nix @@ -62,6 +62,15 @@ let make-krebs-repo = with git; name: { cgit ? {}, ... }: { inherit cgit name; public = true; + hooks = { + post-receive = pkgs.git-hooks.irc-announce { + nick = config.networking.hostName; + verbose = config.krebs.build.host.name == "gum"; + channel = "#xxx"; + # TODO remove the hardcoded hostname + server = "irc.r"; + }; + }; }; diff --git a/makefu/2configs/home-manager/desktop.nix b/makefu/2configs/home-manager/desktop.nix index 3be020faa..63a5cdbef 100644 --- a/makefu/2configs/home-manager/desktop.nix +++ b/makefu/2configs/home-manager/desktop.nix @@ -11,6 +11,15 @@ services.network-manager-applet.enable = true; services.blueman-applet.enable = true; services.pasystray.enable = true; + services.flameshot.enable = true; + home.file.".config/Dharkael/flameshot.ini".text = '' + [General] + disabledTrayIcon=false + drawColor=@Variant(\0\0\0\x43\x1\xff\xff\0\0\0\0\xff\xff\0\0) + drawThickness=0 + filenamePattern=%F_%T_shot + ''; + systemd.user.services.pasystray.Service.Environment = "PATH=" + (lib.makeBinPath (with pkgs;[ pavucontrol paprefs /* pavumeter */ /* paman */ ]) ); programs.chromium = { enable = true; diff --git a/makefu/2configs/home-manager/zsh.nix b/makefu/2configs/home-manager/zsh.nix index 59658e667..6c7b632e1 100644 --- a/makefu/2configs/home-manager/zsh.nix +++ b/makefu/2configs/home-manager/zsh.nix @@ -86,7 +86,8 @@ share = true; }; sessionVariables = { - TERM = "rxvt-unicode-256color"; + # TERM = "rxvt-unicode-256color"; + TERM = "xterm"; LANG = "en_US.UTF8"; LS_COLORS = ":di=1;31:"; EDITOR = "vim"; diff --git a/makefu/2configs/homeautomation/default.nix b/makefu/2configs/homeautomation/default.nix index 596d0002a..2af311c3b 100644 --- a/makefu/2configs/homeautomation/default.nix +++ b/makefu/2configs/homeautomation/default.nix @@ -257,4 +257,8 @@ in { enable = true; #configDir = "/var/lib/hass"; }; + nixpkgs.config.permittedInsecurePackages = [ + "homeassistant-0.77.2" + ]; + } diff --git a/makefu/2configs/homeautomation/google-muell.nix b/makefu/2configs/homeautomation/google-muell.nix index 235cc1546..5870f298d 100644 --- a/makefu/2configs/homeautomation/google-muell.nix +++ b/makefu/2configs/homeautomation/google-muell.nix @@ -3,13 +3,20 @@ with import <stockholm/lib>; let pkg = pkgs.ampel; home = "/var/lib/ampel"; - sec = "${toString <secrets>}/google-muell.json"; + sec = "${toString <secrets>}/ampel/google-muell.json"; ampelsec = "${home}/google-muell.json"; - cred = "${toString <secrets>}/google-muell-creds.json"; + cred = "${toString <secrets>}/ampel/google-muell-creds.json"; # TODO: generate this credential file locally ampelcred = "${home}/google-muell-creds.json"; - esp = "192.168.8.204"; sleepval = "1800"; + default-color = "244,220,66"; + config_json = toFile "config.json" (toJSON { + mq_hostname = "localhost"; + mq_port = 1883; + mq_username = "sensor"; + mq_topic = "/ham/flurlicht/cmnd/MEM1"; + mq_password = replaceChars ["\n"] [""] (readFile "${toString <secrets>}/mqtt/sensor"); + }); in { users.users.ampel = { uid = genid "ampel"; @@ -27,7 +34,7 @@ in { install -m600 -o ampel ${sec} ${ampelsec} install -m600 -o ampel ${cred} ${ampelcred} ''; - ExecStart = "${pkg}/bin/google-muell --esp=${esp} --client-secrets=${ampelsec} --credential-path=${ampelcred} --sleepval=${sleepval}"; + ExecStart = "${pkg}/bin/google-muell --config ${config_json} --default-color=${default-color} --client-secrets=${ampelsec} --credential-path=${ampelcred} --sleepval=${sleepval}"; PermissionsStartOnly = true; Restart = "always"; RestartSec = 10; diff --git a/makefu/2configs/remote-build/gum.nix b/makefu/2configs/remote-build/gum.nix new file mode 100644 index 000000000..98e2e58b5 --- /dev/null +++ b/makefu/2configs/remote-build/gum.nix @@ -0,0 +1,15 @@ +{ + nix = { + distributedBuilds = true; + buildMachines = [ + { + hostName = "gum.krebsco.de"; + maxJobs = 8; + sshKey = toString <secrets/id_nixBuild>; + sshUser = "nixBuild"; + system = "x86_64-linux"; + supportedFeatures = [ ]; + } + ]; + }; +} diff --git a/makefu/2configs/remote-build/slave.nix b/makefu/2configs/remote-build/slave.nix index 89121ffd6..0227f512a 100644 --- a/makefu/2configs/remote-build/slave.nix +++ b/makefu/2configs/remote-build/slave.nix @@ -5,6 +5,7 @@ useDefaultShell = true; openssh.authorizedKeys.keys = [ config.krebs.users.buildbotSlave.pubkey + config.krebs.users.makefu-remote-builder.pubkey ]; }; } diff --git a/makefu/2configs/tools/core-gui.nix b/makefu/2configs/tools/core-gui.nix index 1e85da53c..582d941a6 100644 --- a/makefu/2configs/tools/core-gui.nix +++ b/makefu/2configs/tools/core-gui.nix @@ -2,6 +2,7 @@ { users.users.makefu.packages = with pkgs; [ + at_spi2_core chromium feh clipit diff --git a/makefu/2configs/tools/core.nix b/makefu/2configs/tools/core.nix index 33e896d4c..b4c3a431e 100644 --- a/makefu/2configs/tools/core.nix +++ b/makefu/2configs/tools/core.nix @@ -8,7 +8,6 @@ ( pkgs.writeScriptBin "unknow" ''#!/bin/sh ${gnused}/bin/sed -i "''${1}d" ~/.ssh/known_hosts '') - at_spi2_core acpi bc rsync @@ -17,6 +16,7 @@ ${gnused}/bin/sed -i "''${1}d" ~/.ssh/known_hosts lsof which binutils + screen # fs cifs-utils diff --git a/makefu/2configs/tools/games.nix b/makefu/2configs/tools/games.nix index 40ea4523d..0f1e61791 100644 --- a/makefu/2configs/tools/games.nix +++ b/makefu/2configs/tools/games.nix @@ -2,7 +2,7 @@ { imports = [ - ./steam.nix + # ./steam.nix ]; users.users.makefu.packages = with pkgs; [ games-user-env diff --git a/makefu/5pkgs/ampel/default.nix b/makefu/5pkgs/ampel/default.nix index 9792c2c59..70fdfda78 100644 --- a/makefu/5pkgs/ampel/default.nix +++ b/makefu/5pkgs/ampel/default.nix @@ -2,7 +2,7 @@ with pkgs.python3Packages;buildPythonPackage rec { name = "ampel-${version}"; - version = "0.2.1"; + version = "0.2.4"; propagatedBuildInputs = [ docopt @@ -16,8 +16,8 @@ with pkgs.python3Packages;buildPythonPackage rec { src = pkgs.fetchgit { url = "http://cgit.euer.krebsco.de/ampel"; - rev = "92321d7"; - sha256 = "0mvpbpf1rx8sc589qjb73gl8z6fir2zs3gl3br1pbhg5jgn0ij4n"; + rev = "04e1c8c38ffe53175ae719121ad88534a8a662db"; + sha256 = "00jgr3jg2yi91hd7388v8rncfbq8fx8dvr03sg749dzpsg58hfxn"; }; meta = { homepage = http://cgit.euer.krebsco.de/ampel; diff --git a/makefu/5pkgs/awesomecfg/default.nix b/makefu/5pkgs/awesomecfg/default.nix index 486c0ddf6..1ae2f50d9 100644 --- a/makefu/5pkgs/awesomecfg/default.nix +++ b/makefu/5pkgs/awesomecfg/default.nix @@ -5,6 +5,7 @@ , networkmanagerapplet , blueman , clipit +, flameshot , modkey ? "Mod4" , locker? "${pkgs.xlock}/bin/xlock -mode blank" , ... }: @@ -13,7 +14,7 @@ # replace: @alsaUtils@ @xlockmore@ @xbacklight@ @modkey@ full = lib.makeOverridable pkgs.substituteAll { name = "awesome_full_config"; - inherit alsaUtils locker xbacklight modkey networkmanagerapplet blueman clipit; + inherit alsaUtils locker xbacklight modkey networkmanagerapplet blueman clipit flameshot ; isExecutable = false; src = ./full.cfg; }; diff --git a/makefu/5pkgs/awesomecfg/full.cfg b/makefu/5pkgs/awesomecfg/full.cfg index 11f9f59b8..83dd79b4d 100644 --- a/makefu/5pkgs/awesomecfg/full.cfg +++ b/makefu/5pkgs/awesomecfg/full.cfg @@ -410,6 +410,7 @@ clientkeys = awful.util.table.join( -- minimized, since minimized clients can't have the focus. c.minimized = true end), + awful.key({ }, "Print", function () awful.util.spawn("@flameshot@/bin/flameshot gui") end), awful.key({ modkey, }, "m", function (c) c.maximized = not c.maximized diff --git a/makefu/nixpkgs.json b/makefu/nixpkgs.json index d62fd65ca..7c14f78a8 100644 --- a/makefu/nixpkgs.json +++ b/makefu/nixpkgs.json @@ -1,7 +1,7 @@ { "url": "https://github.com/makefu/nixpkgs", - "rev": "125873064a6eabd2896833d00aede7778a453fdf", - "date": "2019-01-11T14:24:21+01:00", - "sha256": "1ki50426m9simqvxdzckfgycibz5rdhwl6hzi31i72dqiafl8j6s", + "rev": "16fc6279dddabc42f8556d6368ed4215d916794f", + "date": "2019-02-16T22:29:33+01:00", + "sha256": "0bgm0gybqysy1si2zd8b2h6200hgmi8qsyi6qhcnvd4n555f3iic", "fetchSubmodules": false } |