diff options
| -rw-r--r-- | krebs/5pkgs/default.nix | 9 | ||||
| -rw-r--r-- | lass/1systems/helios/config.nix | 10 | ||||
| -rw-r--r-- | lass/1systems/mors/config.nix | 1 | ||||
| -rw-r--r-- | lass/2configs/br.nix | 48 | ||||
| -rw-r--r-- | lass/2configs/default.nix | 1 | ||||
| -rw-r--r-- | lass/2configs/exim-smarthost.nix | 1 | ||||
| -rw-r--r-- | lass/2configs/websites/domsen.nix | 2 | ||||
| -rw-r--r-- | lass/3modules/screenlock.nix | 2 | ||||
| -rw-r--r-- | lass/source.nix | 2 | ||||
| -rw-r--r-- | tv/1systems/xu/config.nix | 2 | ||||
| -rw-r--r-- | tv/2configs/ppp.nix | 32 | ||||
| -rw-r--r-- | tv/5pkgs/default.nix | 8 | 
12 files changed, 107 insertions, 11 deletions
| diff --git a/krebs/5pkgs/default.nix b/krebs/5pkgs/default.nix index af4cbb3ba..84c00e82d 100644 --- a/krebs/5pkgs/default.nix +++ b/krebs/5pkgs/default.nix @@ -13,6 +13,15 @@ foldl' mergeAttrs {}  //  { +  # https://github.com/NixOS/nixpkgs/pull/30065 +  brscan4 = overrideDerivation super.brscan4 (original: rec { +    name = "brscan4-0.4.4-4"; +    src = super.fetchurl { +      url = "http://download.brother.com/welcome/dlf006645/${name}.amd64.deb"; +      sha256 = "0xy5px96y1saq9l80vwvfn6anr2q42qlxdhm6ci2a0diwib5q9fd"; +    }; +  }); +    ReaktorPlugins = self.callPackage ./simple/Reaktor/plugins.nix {};    # https://github.com/proot-me/PRoot/issues/106 diff --git a/lass/1systems/helios/config.nix b/lass/1systems/helios/config.nix index 70aa3832d..c64789d8d 100644 --- a/lass/1systems/helios/config.nix +++ b/lass/1systems/helios/config.nix @@ -105,6 +105,8 @@ with import <stockholm/lib>;      { output = "DP-2"; primary = true; }    ]; +  networking.hostName = lib.mkForce "BLN02NB0162"; +    security.pki.certificateFiles = [     (pkgs.fetchurl { url = "http://pki.dcso.de/ca/PEM/DCSOCAROOTC1G1.pem"; sha256 = "14vz9c0fk6li0a26vx0s5ha6y3yivnshx9pjlh9vmnpkbph5a7rh"; })     (pkgs.fetchurl { url = "http://pki.dcso.de/ca/PEM/DCSOCAROOTC2G1.pem"; sha256 = "0r1dd48a850cv7whk4g2maik550rd0vsrsl73r6x0ivzz7ap1xz5"; }) @@ -117,4 +119,12 @@ with import <stockholm/lib>;    ];    lass.screenlock.command = "${pkgs.i3lock}/bin/i3lock -i /home/lass/lock.png -t -f"; + +  programs.adb.enable = true; +  users.users.mainUser.extraGroups = [ "adbusers" ]; + +  services.printing = { +    enable = true; +    drivers = [ pkgs.postscript-lexmark ]; +  };  } diff --git a/lass/1systems/mors/config.nix b/lass/1systems/mors/config.nix index 610bfef8e..6a61ce1fa 100644 --- a/lass/1systems/mors/config.nix +++ b/lass/1systems/mors/config.nix @@ -29,6 +29,7 @@ with import <stockholm/lib>;      <stockholm/lass/2configs/syncthing.nix>      <stockholm/lass/2configs/otp-ssh.nix>      <stockholm/lass/2configs/c-base.nix> +    <stockholm/tv/2configs/br.nix>      {        #risk of rain port        krebs.iptables.tables.filter.INPUT.rules = [ diff --git a/lass/2configs/br.nix b/lass/2configs/br.nix new file mode 100644 index 000000000..35bac8fee --- /dev/null +++ b/lass/2configs/br.nix @@ -0,0 +1,48 @@ +with import <stockholm/lib>; +{ config, pkgs, ... }: { + +  imports = [ +    <nixpkgs/nixos/modules/services/hardware/sane_extra_backends/brscan4.nix> +  ]; + +  krebs.nixpkgs.allowUnfreePredicate = pkg: any (flip hasPrefix pkg.name) [ +    "brother-udev-rule-type1-" +    "brscan4-" +    "mfcl2700dnlpr-" +  ]; + +  hardware.sane = { +    enable = true; +    brscan4 = { +      enable = true; +      netDevices = { +        bra = { +          model = "MFCL2700DN"; +          ip = "10.23.42.221"; +        }; +      }; +    }; +  }; + +  services.saned.enable = true; + +  # usage: scanimage -d "$(find-scanner bra)" --batch --format=tiff --resolution 150  -x 211 -y 298 +  environment.systemPackages = [ +    (pkgs.writeDashBin "find-scanner" '' +      set -efu +      name=$1 +      ${pkgs.sane-backends}/bin/scanimage -f '%m %d +      ' \ +      | ${pkgs.gawk}/bin/awk -v dev="*$name" '$1 == dev { print $2; exit }' \ +      | ${pkgs.gnugrep}/bin/grep . +    '') +  ]; + +  services.printing = { +    enable = true; +    drivers = [ +      pkgs.mfcl2700dncupswrapper +    ]; +  }; + +} diff --git a/lass/2configs/default.nix b/lass/2configs/default.nix index 10d14e151..180647a6d 100644 --- a/lass/2configs/default.nix +++ b/lass/2configs/default.nix @@ -210,6 +210,7 @@ with import <stockholm/lib>;          { predicate = "-p tcp -i retiolum"; target = "REJECT --reject-with tcp-reset"; precedence = -10000; }          { predicate = "-p udp -i retiolum"; target = "REJECT --reject-with icmp-port-unreachable"; v6 = false; precedence = -10000; }          { predicate = "-i retiolum"; target = "REJECT --reject-with icmp-proto-unreachable"; v6 = false; precedence = -10000; } +        { predicate = "-i retiolum -p udp -m udp --dport 53"; target = "ACCEPT"; }        ];      };    }; diff --git a/lass/2configs/exim-smarthost.nix b/lass/2configs/exim-smarthost.nix index 0b56f6f47..f9c8f8ebc 100644 --- a/lass/2configs/exim-smarthost.nix +++ b/lass/2configs/exim-smarthost.nix @@ -45,6 +45,7 @@ with import <stockholm/lib>;        { from = "raf@lassul.us"; to = lass.mail; }        { from = "apple@lassul.us"; to = lass.mail; }        { from = "coinbase@lassul.us"; to = lass.mail; } +      { from = "tomtop@lassul.us"; to = lass.mail; }      ];      system-aliases = [        { from = "mailer-daemon"; to = "postmaster"; } diff --git a/lass/2configs/websites/domsen.nix b/lass/2configs/websites/domsen.nix index 10ff142f9..6fbd4d0df 100644 --- a/lass/2configs/websites/domsen.nix +++ b/lass/2configs/websites/domsen.nix @@ -126,6 +126,8 @@ in {        { from = "dominik@apanowicz.de"; to = "dominik_a@gmx.de"; }        { from = "dma@ubikmedia.de"; to = "domsen"; }        { from = "dma@ubikmedia.eu"; to = "domsen"; } +      { from = "mail@habsys.de"; to = "domsen"; } +      { from = "mail@habsys.eu"; to = "domsen"; }        { from = "bruno@apanowicz.de"; to = "bruno"; }        { from = "mail@jla-trading.com"; to = "jla-trading"; }        { from = "jms@ubikmedia.eu"; to = "jms"; } diff --git a/lass/3modules/screenlock.nix b/lass/3modules/screenlock.nix index cf38f8357..06ca1f27d 100644 --- a/lass/3modules/screenlock.nix +++ b/lass/3modules/screenlock.nix @@ -11,7 +11,7 @@ let    };    api = { -    enable = mkEnableOption "news"; +    enable = mkEnableOption "screenlock";      command = mkOption {        type = types.str;        default = "${pkgs.i3lock}/bin/i3lock -i /var/lib/wallpaper/wallpaper -f"; diff --git a/lass/source.nix b/lass/source.nix index 910d70334..738504228 100644 --- a/lass/source.nix +++ b/lass/source.nix @@ -10,7 +10,7 @@ in        nixos-config.symlink = "stockholm/lass/1systems/${name}/config.nix";        nixpkgs.git = {          url = https://github.com/nixos/nixpkgs; -        ref = "c99239b"; +        ref = "e53e9a2";        };        secrets.file = getAttr builder {          buildbot = toString <stockholm/lass/2configs/tests/dummy-secrets>; diff --git a/tv/1systems/xu/config.nix b/tv/1systems/xu/config.nix index 0363c983d..14926fe3b 100644 --- a/tv/1systems/xu/config.nix +++ b/tv/1systems/xu/config.nix @@ -13,6 +13,7 @@ with import <stockholm/lib>;      <stockholm/tv/2configs/man.nix>      <stockholm/tv/2configs/nginx/krebs-pages.nix>      <stockholm/tv/2configs/nginx/public_html.nix> +    <stockholm/tv/2configs/ppp.nix>      <stockholm/tv/2configs/pulse.nix>      <stockholm/tv/2configs/retiolum.nix>      <stockholm/tv/2configs/binary-cache> @@ -99,7 +100,6 @@ with import <stockholm/lib>;          #tlsdate          #unetbootin          #utillinuxCurses -        #wvdial          #xdotool          #xkill          #xl2tpd diff --git a/tv/2configs/ppp.nix b/tv/2configs/ppp.nix new file mode 100644 index 000000000..9cc7568a5 --- /dev/null +++ b/tv/2configs/ppp.nix @@ -0,0 +1,32 @@ +{ pkgs, ... }: { + +  # usage: pppd call default + +  environment.etc."ppp/peers/default".text = '' +    /dev/ttyACM2 +    921600 +    crtscts +    defaultroute +    holdoff 10 +    lock +    maxfail 0 +    noauth +    nodetach +    noipdefault +    passive +    persist +    usepeerdns +    connect "${pkgs.ppp}/bin/chat -f ${pkgs.writeText "default.chat" '' +      ABORT "BUSY" +      ABORT "NO CARRIER" +      REPORT CONNECT +      "" "ATDT*99#" +      CONNECT +    ''}" +  ''; + +  environment.systemPackages = [ +    pkgs.ppp +  ]; + +} diff --git a/tv/5pkgs/default.nix b/tv/5pkgs/default.nix index 9dc7ae7b1..261871e62 100644 --- a/tv/5pkgs/default.nix +++ b/tv/5pkgs/default.nix @@ -13,14 +13,6 @@ foldl' mergeAttrs {}  //  { -  brscan4 = overrideDerivation super.brscan4 (original: rec { -    name = "brscan4-0.4.4-4"; -    src = super.fetchurl { -      url = "http://download.brother.com/welcome/dlf006645/${name}.amd64.deb"; -      sha256 = "0xy5px96y1saq9l80vwvfn6anr2q42qlxdhm6ci2a0diwib5q9fd"; -    }; -  }); -    # TODO use XDG_RUNTIME_DIR?    cr = self.writeDashBin "cr" ''      set -efu | 
