From 2a03084240be70f186abe731d4e22ba1a0464154 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 14 Aug 2017 23:32:27 +0200 Subject: [PATCH 01/41] l newsbot-js: sort feeds --- lass/2configs/newsbot-js.nix | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/lass/2configs/newsbot-js.nix b/lass/2configs/newsbot-js.nix index 9983fd567..5e028a3fb 100644 --- a/lass/2configs/newsbot-js.nix +++ b/lass/2configs/newsbot-js.nix @@ -15,7 +15,6 @@ let bdt_plenarproto|http://www.bundestag.de/rss_feeds/plenarprotokolle.rss|#news #bundestag bdt_pressemitteilungen|http://www.bundestag.de/blueprint/servlet/service/de/273112/asFeed/index.rss|#news bitcoinpakistan|https://bitcoinspakistan.com/feed/|#news #financial - c|http://www.tempolimit-lichtgeschwindigkeit.de/news.xml|#news cancer|http://feeds.feedburner.com/ncinewsreleases?format=xml|#news carta|http://feeds2.feedburner.com/carta-standard-rss|#news catholic_news|http://feeds.feedburner.com/catholicnewsagency/dailynews|#news @@ -27,7 +26,11 @@ let ccc|http://www.ccc.de/rss/updates.rdf|#news chan_b|https://boards.4chan.org/b/index.rss|#brainfuck chan_biz|https://boards.4chan.org/biz/index.rss|#news #brainfuck + chan_g|https://boards.4chan.org/g/index.rss|#news chan_int|https://boards.4chan.org/int/index.rss|#news #brainfuck + chan_sci|https://boards.4chan.org/sci/index.rss|#news + chan_x|https://boards.4chan.org/x/index.rss|#news + c|http://www.tempolimit-lichtgeschwindigkeit.de/news.xml|#news cryptogon|http://www.cryptogon.com/?feed=rss2|#news csm|http://rss.csmonitor.com/feeds/csm|#news csm_world|http://rss.csmonitor.com/feeds/world|#news @@ -61,6 +64,7 @@ let greenpeace|http://feeds.feedburner.com/GreenpeaceNews|#news guardian_uk|http://feeds.theguardian.com/theguardian/uk-news/rss|#news gulli|http://ticker.gulli.com/rss/|#news + hackernews|https://news.ycombinator.com/rss|#news handelsblatt|http://www.handelsblatt.com/contentexport/feed/schlagzeilen|#news #financial heise|https://www.heise.de/newsticker/heise-atom.xml|#news hindu_business|http://www.thehindubusinessline.com/?service=rss|#news #financial @@ -100,7 +104,12 @@ let reddit_4chan|http://www.reddit.com/r/4chan/new/.rss|#news #brainfuck reddit_anticonsum|http://www.reddit.com/r/Anticonsumption/new/.rss|#news reddit_btc|http://www.reddit.com/r/Bitcoin/new/.rss|#news #financial + reddit_consp|http://reddit.com/r/conspiracy/.rss|#news + reddit_haskell|http://www.reddit.com/r/haskell/.rss|#news + reddit_nix|http://www.reddit.com/r/nixos/.rss|#news reddit_prog|http://www.reddit.com/r/programming/new/.rss|#news + reddit_sci|http://www.reddit.com/r/science/.rss|#news + reddit_tech|http://www.reddit.com/r/technology/.rss|#news reddit_tpp|http://www.reddit.com/r/twitchplayspokemon/.rss|#news #tpp reddit_world|http://www.reddit.com/r/worldnews/.rss|#news r-ethereum|http://www.reddit.com/r/ethereum/.rss|#news @@ -156,16 +165,6 @@ let wp_world|http://feeds.washingtonpost.com/rss/rss_blogpost|#news xkcd|https://xkcd.com/rss.xml|#news zdnet|http://www.zdnet.com/news/rss.xml|#news - - chan_g|https://boards.4chan.org/g/index.rss|#news - chan_x|https://boards.4chan.org/x/index.rss|#news - chan_sci|https://boards.4chan.org/sci/index.rss|#news - reddit_consp|http://reddit.com/r/conspiracy/.rss|#news - reddit_sci|http://www.reddit.com/r/science/.rss|#news - reddit_tech|http://www.reddit.com/r/technology/.rss|#news - reddit_nix|http://www.reddit.com/r/nixos/.rss|#news - reddit_haskell|http://www.reddit.com/r/haskell/.rss|#news - hackernews|https://news.ycombinator.com/rss|#news ''; in { environment.systemPackages = [ From 22b94883629dd81d87c61695a3d54edd62458af2 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 14 Aug 2017 23:34:53 +0200 Subject: [PATCH 02/41] l mors.r: remove thunderbird --- lass/1systems/mors/config.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/lass/1systems/mors/config.nix b/lass/1systems/mors/config.nix index 2cb6a7519..5bc52d633 100644 --- a/lass/1systems/mors/config.nix +++ b/lass/1systems/mors/config.nix @@ -139,7 +139,6 @@ with import ; urban mk_sql_pair remmina - thunderbird iodine From 82a01f5e7abc1009ee406f4a48e2a9d7794e50ae Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 14 Aug 2017 23:37:40 +0200 Subject: [PATCH 03/41] l: add radio@lassul.us --- lass/2configs/exim-smarthost.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/lass/2configs/exim-smarthost.nix b/lass/2configs/exim-smarthost.nix index 728e265f6..611e1b9da 100644 --- a/lass/2configs/exim-smarthost.nix +++ b/lass/2configs/exim-smarthost.nix @@ -40,6 +40,7 @@ with import ; { from = "patreon@lassul.us"; to = lass.mail; } { from = "steam@lassul.us"; to = lass.mail; } { from = "securityfocus@lassul.us"; to = lass.mail; } + { from = "radio@lassul.us"; to = lass.mail; } ]; system-aliases = [ { from = "mailer-daemon"; to = "postmaster"; } From 82fecfe30e6e6e74eb144bd943235d3901b641e9 Mon Sep 17 00:00:00 2001 From: makefu Date: Tue, 15 Aug 2017 14:43:35 +0200 Subject: [PATCH 04/41] ma source: bump to 9d4bd6b --- makefu/source.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/makefu/source.nix b/makefu/source.nix index 0c74585b2..31243c2fd 100644 --- a/makefu/source.nix +++ b/makefu/source.nix @@ -11,7 +11,10 @@ let then "buildbot" else "makefu"; _file = + "/makefu/1systems/${name}/source.nix"; - ref = "1e47827"; # unstable @ 2017-07-31 + graceful requests2 (a772c3aa) + libpurple bitlbee ( ce6fe1a, 65e38b7 ) + ref = "9d4bd6b"; # unstable @ 2017-07-31 + # + graceful requests2 (a772c3aa) + # + libpurple bitlbee ( ce6fe1a, 65e38b7 ) + # + buildbot-runner ( f3cecc5 ) in evalSource (toString _file) [ From 34c654b7149702a2fff64d36fe7bedb0f09e74d6 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 08:42:57 +0200 Subject: [PATCH 05/41] ma gitlab-runner-shackspace: init --- .../2configs/git/gitlab-runner-shackspace.nix | 32 +++++++++++++++++++ .../secrets/shackspace-gitlab-ci-token.nix | 1 + 2 files changed, 33 insertions(+) create mode 100644 makefu/2configs/git/gitlab-runner-shackspace.nix create mode 100644 makefu/6tests/data/secrets/shackspace-gitlab-ci-token.nix diff --git a/makefu/2configs/git/gitlab-runner-shackspace.nix b/makefu/2configs/git/gitlab-runner-shackspace.nix new file mode 100644 index 000000000..a5a1247ba --- /dev/null +++ b/makefu/2configs/git/gitlab-runner-shackspace.nix @@ -0,0 +1,32 @@ +{ config, ... }: +let + url = "https://git.shackspace.de/"; + # generate token from CI-token via: + ## gitlab-runner register + token = import ; +in { + virtualisation.docker.enable = true; + services.gitlab-runner = { + enable = true; + gracefulTimeout = "120min"; + # configFile = "/var/src/secrets/runner.toml"; + configOptions = { + concurrent = 2; + runners = [{ + name = "nix-krebs-1.11"; + inherit token url; + executor = "docker"; + builds_dir = ""; + docker = { + host = ""; + image = "nixos/nix:1.11"; + privileged = false; + disable_cache = false; + volumes = ["/cache"]; + shm_size = 0; + }; + cache = {}; + }]; + }; + }; +} diff --git a/makefu/6tests/data/secrets/shackspace-gitlab-ci-token.nix b/makefu/6tests/data/secrets/shackspace-gitlab-ci-token.nix new file mode 100644 index 000000000..963e6db8b --- /dev/null +++ b/makefu/6tests/data/secrets/shackspace-gitlab-ci-token.nix @@ -0,0 +1 @@ +"lol" From ab219696a6c8d02ecb75baa7f0f590ce4964b06b Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 08:43:28 +0200 Subject: [PATCH 06/41] ma gitlab: init --- makefu/2configs/deployment/gitlab.nix | 39 +++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 makefu/2configs/deployment/gitlab.nix diff --git a/makefu/2configs/deployment/gitlab.nix b/makefu/2configs/deployment/gitlab.nix new file mode 100644 index 000000000..d61f50c1d --- /dev/null +++ b/makefu/2configs/deployment/gitlab.nix @@ -0,0 +1,39 @@ +{ lib, config, ... }: +let + web-port = 19453; + hostn = "gitlab.makefu.r"; + internal-ip = config.krebs.build.host.nets.retiolum.ip4.addr; +in { + + services.gitlab = { + enable = true; + https = false; + port = web-port; + secrets = import ; + databasePassword = import ; + initialRootEmail = "makefu@x.r"; + initialRootPassword = import ; + host = hostn; + smtp = { + enable = true; + domain = "r"; + enableStartTLSAuto = false; + port = 25; + }; + }; + + services.nginx = { + enable = lib.mkDefault true; + virtualHosts."${hostn}".locations."/" = { + proxyPass = "http://localhost:${toString web-port}/"; + extraConfig = '' + if ( $server_addr != "${internal-ip}" ) { + return 403; + } + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + ''; + }; + }; +} From f390dcb8b5169ca77131e9398cae50d46023a979 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 08:44:57 +0200 Subject: [PATCH 07/41] ma tools: add gitFull --- makefu/2configs/tools/extra-gui.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/makefu/2configs/tools/extra-gui.nix b/makefu/2configs/tools/extra-gui.nix index 1e68e935c..b2d616764 100644 --- a/makefu/2configs/tools/extra-gui.nix +++ b/makefu/2configs/tools/extra-gui.nix @@ -13,5 +13,6 @@ # Dev saleae-logic arduino-user-env + gitAndTools.gitFull ]; } From 68ee2d5c674fe3930dd8e93fc2ad0c0d1f1a97db Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 08:46:48 +0200 Subject: [PATCH 08/41] ma nsupdate-data: init --- makefu/2configs/nsupdate-data.nix | 55 ++++++++++++++++++++ makefu/6tests/data/secrets/nsupdate-data.nix | 1 + 2 files changed, 56 insertions(+) create mode 100644 makefu/2configs/nsupdate-data.nix create mode 100644 makefu/6tests/data/secrets/nsupdate-data.nix diff --git a/makefu/2configs/nsupdate-data.nix b/makefu/2configs/nsupdate-data.nix new file mode 100644 index 000000000..cfa6193c6 --- /dev/null +++ b/makefu/2configs/nsupdate-data.nix @@ -0,0 +1,55 @@ +{ config, lib, pkgs, ... }: + +# search also generates ddclient entries for all other logs + +with import ; +let + #primary-itf = "eth0"; + #primary-itf = "wlp2s0"; + primary-itf = config.makefu.server.primary-itf; + ddclientUser = "ddclient"; + sec = toString ; + nsupdate = import "${sec}/nsupdate-data.nix"; + stateDir = "/var/spool/ddclient"; + cfg = "${stateDir}/cfg"; + ddclientPIDFile = "${stateDir}/ddclient.pid"; + + # TODO: correct cert generation requires a `real` internet ip address + + gen-cfg = dict: '' + ssl=yes + cache=${stateDir}/ddclient.cache + pid=${ddclientPIDFile} + ${concatStringsSep "\n" (mapAttrsToList (user: pass: '' + + use=if, if=${primary-itf} protocol=dyndns2, server=ipv4.nsupdate.info, login=${user}, password='${pass}' ${user} + usev6=if, if=${primary-itf} protocol=dyndns2, server=ipv6.nsupdate.info, login=${user}, password='${pass}' ${user} + '') dict)} + ''; + +in { + users.extraUsers = singleton { + name = ddclientUser; + uid = genid "ddclient"; + description = "ddclient daemon user"; + home = stateDir; + createHome = true; + }; + + systemd.services = { + ddclient-nsupdate-elchos = { + wantedBy = [ "multi-user.target" ]; + after = [ "ip-up.target" ]; + serviceConfig = { + Type = "forking"; + User = ddclientUser; + PIDFile = ddclientPIDFile; + ExecStartPre = pkgs.writeDash "init-nsupdate" '' + cp -vf ${pkgs.writeText "ddclient-config" (gen-cfg nsupdate)} ${cfg} + chmod 700 ${cfg} + ''; + ExecStart = "${pkgs.ddclient}/bin/ddclient -verbose -daemon 1 -noquiet -file ${cfg}"; + }; + }; + }; +} diff --git a/makefu/6tests/data/secrets/nsupdate-data.nix b/makefu/6tests/data/secrets/nsupdate-data.nix new file mode 100644 index 000000000..e76c0e87e --- /dev/null +++ b/makefu/6tests/data/secrets/nsupdate-data.nix @@ -0,0 +1 @@ +{ "lol" = "wut"; } From 1342a5ab5dad9553e20016e91aa8c641629ecf82 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 08:47:19 +0200 Subject: [PATCH 09/41] ma lanparty: add samba --- makefu/2configs/lanparty/samba.nix | 31 ++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 makefu/2configs/lanparty/samba.nix diff --git a/makefu/2configs/lanparty/samba.nix b/makefu/2configs/lanparty/samba.nix new file mode 100644 index 000000000..de834ab16 --- /dev/null +++ b/makefu/2configs/lanparty/samba.nix @@ -0,0 +1,31 @@ +{config, ... }:{ + networking.firewall.allowedUDPPorts = [ 137 138 ]; + networking.firewall.allowedTCPPorts = [ 139 445 ]; + users.users.smbguest = { + name = "smbguest"; + uid = config.ids.uids.smbguest; + description = "smb guest user"; + home = "/data/lanparty"; + createHome = true; + }; + services.samba = { + enable = true; + shares = { + share-home = { + path = "/data/lanparty/"; + "read only" = "no"; + browseable = "yes"; + "guest ok" = "yes"; + }; + }; + extraConfig = '' + guest account = smbguest + map to guest = bad user + # disable printing + load printers = no + printing = bsd + printcap name = /dev/null + disable spoolss = yes + ''; + }; +} From 5b35e728d1da88900147639f7203df1b589b69e5 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 08:48:13 +0200 Subject: [PATCH 10/41] ma pkgs.cmpforopenssl: init --- makefu/5pkgs/cmpforopenssl/default.nix | 82 +++++++++++++++++++ .../cmpforopenssl/nix-ssl-cert-file.patch | 14 ++++ 2 files changed, 96 insertions(+) create mode 100644 makefu/5pkgs/cmpforopenssl/default.nix create mode 100644 makefu/5pkgs/cmpforopenssl/nix-ssl-cert-file.patch diff --git a/makefu/5pkgs/cmpforopenssl/default.nix b/makefu/5pkgs/cmpforopenssl/default.nix new file mode 100644 index 000000000..3b9a20098 --- /dev/null +++ b/makefu/5pkgs/cmpforopenssl/default.nix @@ -0,0 +1,82 @@ +{ stdenv, fetchurl, buildPackages, perl, fetchgit +, hostPlatform +}: + +with stdenv.lib; + +let + + common = args@{ rev, sha256, patches ? [] }: stdenv.mkDerivation rec { + name = "cmpforopenssl-${rev}"; + + src = fetchgit { + url = "https://git.code.sf.net/p/cmpforopenssl/git"; + inherit sha256 rev; + fetchSubmodules = false; + deepClone = false; + }; + + patches = + (args.patches or []) + ++ [ ./nix-ssl-cert-file.patch ]; + + outputs = [ "bin" "dev" "out" "man" ]; + setOutputFlags = false; + separateDebugInfo = stdenv.isLinux; + + nativeBuildInputs = [ perl ]; + + configureScript = "./config"; + + configureFlags = [ + "shared" + "--libdir=lib" + "--openssldir=etc/ssl" + ] ; + + makeFlags = [ "MANDIR=$(man)/share/man" ]; + + # Parallel building is broken in OpenSSL. + enableParallelBuilding = false; + + postInstall = '' + # If we're building dynamic libraries, then don't install static + # libraries. + if [ -n "$(echo $out/lib/*.so $out/lib/*.dylib $out/lib/*.dll)" ]; then + rm "$out/lib/"*.a + fi + + mkdir -p $bin + mv $out/bin $bin/ + + mkdir $dev + mv $out/include $dev/ + + # remove dependency on Perl at runtime + rm -r $out/etc/ssl/misc + + rmdir $out/etc/ssl/{certs,private} + ''; + + postFixup = '' + # Check to make sure the main output doesn't depend on perl + if grep -r '${buildPackages.perl}' $out; then + echo "Found an erroneous dependency on perl ^^^" >&2 + exit 1 + fi + ''; + + + meta = { + homepage = https://sourceforge.net/p/cmpforopenssl ; + description = "A cryptographic library that implements the SSL and TLS protocols"; + platforms = stdenv.lib.platforms.all; + maintainers = [ stdenv.lib.maintainers.makefu ]; + priority = 0; # resolves collision with ‘man-pages’ + }; + }; + +in common { + rev = "462b3"; + sha256 = "1h2k1c4lg27gmsyd72zrlr303jw765x8sscxblq2jwb44jag85na"; + } diff --git a/makefu/5pkgs/cmpforopenssl/nix-ssl-cert-file.patch b/makefu/5pkgs/cmpforopenssl/nix-ssl-cert-file.patch new file mode 100644 index 000000000..b615f1482 --- /dev/null +++ b/makefu/5pkgs/cmpforopenssl/nix-ssl-cert-file.patch @@ -0,0 +1,14 @@ +diff -ru -x '*~' openssl-1.0.2j-orig/crypto/x509/by_file.c openssl-1.0.2j/crypto/x509/by_file.c +--- openssl-1.0.2j-orig/crypto/x509/by_file.c 2016-09-26 11:49:07.000000000 +0200 ++++ openssl-1.0.2j/crypto/x509/by_file.c 2016-10-13 16:54:31.400288302 +0200 +@@ -97,7 +97,9 @@ + switch (cmd) { + case X509_L_FILE_LOAD: + if (argl == X509_FILETYPE_DEFAULT) { +- file = (char *)getenv(X509_get_default_cert_file_env()); ++ file = (char *)getenv("NIX_SSL_CERT_FILE"); ++ if (!file) ++ file = (char *)getenv(X509_get_default_cert_file_env()); + if (file) + ok = (X509_load_cert_crl_file(ctx, file, + X509_FILETYPE_PEM) != 0); From c4940d5926bcd2e938b914568161f63125926369 Mon Sep 17 00:00:00 2001 From: lassulus Date: Wed, 16 Aug 2017 11:36:34 +0200 Subject: [PATCH 11/41] l prism.r: add container for kaepsele --- lass/1systems/prism/config.nix | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/lass/1systems/prism/config.nix b/lass/1systems/prism/config.nix index 5d05ae399..744bae551 100644 --- a/lass/1systems/prism/config.nix +++ b/lass/1systems/prism/config.nix @@ -298,6 +298,22 @@ in { localAddress = "10.233.2.2"; }; } + { + #kaepsele + containers.kaepsele = { + config = { ... }: { + services.openssh.enable = true; + users.users.root.openssh.authorizedKeys.keys = with config.krebs.users; [ + lass.pubkey + tv.pubkey + ]; + }; + enableTun = true; + privateNetwork = true; + hostAddress = "10.233.2.3"; + localAddress = "10.233.2.4"; + }; + } ]; krebs.build.host = config.krebs.hosts.prism; From 0cb6eaf20544a5993d18123bcd6d8e1e938c0d1c Mon Sep 17 00:00:00 2001 From: lassulus Date: Wed, 16 Aug 2017 01:01:33 +0200 Subject: [PATCH 12/41] kaepsele.r: move to prism container --- krebs/3modules/tv/default.nix | 23 ++++++++--------------- 1 file changed, 8 insertions(+), 15 deletions(-) diff --git a/krebs/3modules/tv/default.nix b/krebs/3modules/tv/default.nix index 81db2d411..68cba633b 100644 --- a/krebs/3modules/tv/default.nix +++ b/krebs/3modules/tv/default.nix @@ -113,14 +113,6 @@ with import ; }; kaepsele = { nets = { - internet = { - ip4.addr = "92.222.10.169"; - aliases = [ - "kaepsele.i" - "kaepsele.internet" - # TODO "kaepsele.org" - ]; - }; retiolum = { ip4.addr = "10.243.166.2"; ip6.addr = "42:b9d:6660:d07c:2bb7:4e91:1a01:2e7d"; @@ -129,17 +121,18 @@ with import ; ]; tinc.pubkey = '' -----BEGIN RSA PUBLIC KEY----- - MIIBCgKCAQEAxj7kaye4pGLou7mVRTVgtcWFjuEosJlxVg24gM7nU1EaoRnBD93/ - Y3Je7BSUbz5xMXr5SFTPSkitInL7vU+jDOf2bEpqv+uUJAJIz85494oPS9xocdWo - rQsrQRAtOg4MLD+YIoAxQm2Mc4nt2CSE1+UP4uXGxpuh0c051b+9Kmwv1bTyHB9y - y01VSkDvNyHk5eA+RGDiujBAzhi35hzTlQgCJ3REOBiq4YmE1d3qpk3oNiYUcrcu - yFzQrSRIfhXjuzIR+wxqS95HDUsewSwt9HgkjJzYF5sQZSea0/XsroFqZyTJ8iB5 - FQx2emBqB525cWKOt0f5jgyjklhozhJyiwIDAQAB + MIIBCgKCAQEA4+kDaKhCBNlpHqRCA2R6c4UEFk0OaiPwHvjmBBjpihTJVyffIEYm + QFZ5ZNkaVumSOAgKk9ygppO9WsNasl1ag+IRWik9oupdzEkNjgvOMBVJGhcwGZGF + 6UEY5sdA1n0qg74og5BGSiXUBiaahVM0rAfCNk8gV3qrot5kWJMQLb9BKabJ56eb + JrgWepxuVaw3BoEhz6uusuvw5i1IF382L8R11hlvyefifXONFOAUjCrCr0bCb4uK + ZZcRUU35pbHLDXXTOrOarOO1tuVGu85VXo3S1sLaaouHYjhTVT8bxqbwcNhxBXYf + ONLv0f7G5XwecgUNbE6ZTfjV5PQKaww3lwIDAQAB -----END RSA PUBLIC KEY----- ''; }; }; - ssh.pubkey = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDA9cDUg7qm37uOhQpdKSgpnJPWao9VZR6LFNphVcJQ++gYvVgWu6WMhigiy7DcGQSStUlXkZc4HZBBugwwNWcf7aAF6ijBuG5rVwb9AFQmSexpTOfWap33iA5f+LXYFHe7iv4Pt9TYO1ga1Ryl4EGKb7ol2h5vbKC+JiGaDejB0WqhBAyrTg4tTWO8k2JT11CrlTjNVctqV0IVAMtTc/hcJcNusnoGD4ic0QGSzEMYxcIGRNvIgWmxhI6GHeaHxXWH5fv4b0OpLlDfVUsIvEo9KVozoLGm/wgLBG/tQXKaF9qVMVgOYi9sX/hDLwhRrcD2cyAlq9djo2pMARYiriXF"; + ssh.privkey.path = ; + ssh.pubkey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIC5Wr36T0MmB8pnSO5/pw9/Dfe5+IMgVHOhm6EUa55jj"; }; mu = { cores = 2; From 188d579fdf326cf24f5dc6843ffe5aa2caaaf80b Mon Sep 17 00:00:00 2001 From: lassulus Date: Wed, 16 Aug 2017 11:37:37 +0200 Subject: [PATCH 13/41] echelon.i: set new ip --- krebs/3modules/lass/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/krebs/3modules/lass/default.nix b/krebs/3modules/lass/default.nix index cae0d1f37..7aeeb1f21 100644 --- a/krebs/3modules/lass/default.nix +++ b/krebs/3modules/lass/default.nix @@ -43,7 +43,7 @@ with import ; cores = 2; nets = rec { internet = { - ip4.addr = "104.233.79.118"; + ip4.addr = "45.62.226.163"; aliases = [ "echelon.i" ]; From 619af589d108040a78e753040a857bc58b51e78e Mon Sep 17 00:00:00 2001 From: lassulus Date: Wed, 16 Aug 2017 11:37:58 +0200 Subject: [PATCH 14/41] l iso: set networkingHostname --- lass/1systems/iso.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/lass/1systems/iso.nix b/lass/1systems/iso.nix index 0b048a2b1..be064bed2 100644 --- a/lass/1systems/iso.nix +++ b/lass/1systems/iso.nix @@ -37,6 +37,7 @@ with import ; }; }; boot.kernelParams = [ "copytoram" ]; + networking.hostName = "lass-iso"; } { krebs.enable = true; From f328ae8948d0f6c7070803adbf036872e1667ff4 Mon Sep 17 00:00:00 2001 From: lassulus Date: Wed, 16 Aug 2017 11:38:26 +0200 Subject: [PATCH 15/41] l ircd: remove obsolete netword description --- lass/2configs/ircd.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/lass/2configs/ircd.nix b/lass/2configs/ircd.nix index b72e2b087..ee4c0216c 100644 --- a/lass/2configs/ircd.nix +++ b/lass/2configs/ircd.nix @@ -13,7 +13,6 @@ sid = "1as"; description = "miep!"; network_name = "irc.retiolum"; - network_desc = "Retiolum IRC Network"; hub = yes; vhost = "0.0.0.0"; From f8c0bcf1e9e4d4dd660e6fe82017e28dbbfd6024 Mon Sep 17 00:00:00 2001 From: lassulus Date: Wed, 16 Aug 2017 11:38:45 +0200 Subject: [PATCH 16/41] l mail: show unread first --- lass/2configs/mail.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lass/2configs/mail.nix b/lass/2configs/mail.nix index ee0c3f938..9f9bb24fa 100644 --- a/lass/2configs/mail.nix +++ b/lass/2configs/mail.nix @@ -72,13 +72,13 @@ let ''} %r |" virtual-mailboxes \ + "Unread" "notmuch://?query=tag:unread"\ "INBOX" "notmuch://?query=tag:inbox \ and NOT tag:killed \ and NOT to:shackspace \ and NOT to:c-base \ and NOT from:security-alert@hpe.com \ and NOT to:nix-devel"\ - "Unread" "notmuch://?query=tag:unread"\ "shack" "notmuch://?query=to:shackspace"\ "c-base" "notmuch://?query=to:c-base"\ "security" "notmuch://?query=to:securityfocus or from:security-alert@hpe.com"\ From 8f14ff2f54167c8505de82f65d640a1bb0018f17 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 11:49:17 +0200 Subject: [PATCH 17/41] ma darth: init full-disk-encryption --- makefu/1systems/darth/config.nix | 95 ++++++++++++++++++-------------- 1 file changed, 55 insertions(+), 40 deletions(-) diff --git a/makefu/1systems/darth/config.nix b/makefu/1systems/darth/config.nix index 9dbe67429..7accb13d3 100644 --- a/makefu/1systems/darth/config.nix +++ b/makefu/1systems/darth/config.nix @@ -3,44 +3,62 @@ with import ; let byid = dev: "/dev/disk/by-id/" + dev; - rootDisk = byid "ata-ADATA_SSD_S599_64GB_10460000000000000039"; - auxDisk = byid "ata-HGST_HTS721010A9E630_JR10006PH3A02F"; - dataPartition = auxDisk + "-part1"; + rootDisk = byid "ata-INTEL_SSDSC2BW480H6_CVTR53120385480EGN"; + bootPart = rootDisk + "-part1"; + rootPart = rootDisk + "-part2"; allDisks = [ rootDisk ]; # auxDisk in { imports = [ - + + - + # - - ]; - services.samba.shares = { - isos = { - path = "/data/isos/"; - "read only" = "yes"; - browseable = "yes"; - "guest ok" = "yes"; - }; - }; - services.tinc.networks.siem = { - name = "sdarth"; - extraConfig = "ConnectTo = sjump"; - }; + + + + + # SIEM + # + # {services.tinc.networks.siem = { + # name = "sdarth"; + # extraConfig = "ConnectTo = sjump"; + # }; + # } + + # { + # makefu.forward-journal = { + # enable = true; + # src = "10.8.10.2"; + # dst = "10.8.10.6"; + # }; + # } + + ## Sharing + # + #{ + # services.samba.shares = { + # isos = { + # path = "/data/isos/"; + # "read only" = "yes"; + # browseable = "yes"; + # "guest ok" = "yes"; + # }; + # }; + #} + + ]; + - makefu.forward-journal = { - enable = true; - src = "10.8.10.2"; - dst = "10.8.10.6"; - }; #networking.firewall.enable = false; - + makefu.server.primary-itf = "enp0s25"; + krebs.hidden-ssh.enable = true; boot.kernelModules = [ "coretemp" "f71882fg" ]; hardware.enableAllFirmware = true; nixpkgs.config.allowUnfree = true; @@ -49,31 +67,28 @@ in { firewall = { allowPing = true; logRefusedConnections = false; - trustedInterfaces = [ "eno1" ]; + # trustedInterfaces = [ "eno1" ]; allowedUDPPorts = [ 80 655 1655 67 ]; allowedTCPPorts = [ 80 655 1655 ]; }; # fallback connection to the internal virtual network - interfaces.virbr3.ip4 = [{ - address = "10.8.8.2"; - prefixLength = 24; - }]; + # interfaces.virbr3.ip4 = [{ + # address = "10.8.8.2"; + # prefixLength = 24; + # }]; }; # TODO smartd omo darth gum all-in-one services.smartd.devices = builtins.map (x: { device = x; }) allDisks; - zramSwap.enable = true; - - #fileSystems."/data" = { - # device = dataPartition; - # fsType = "ext4"; - #}; boot.loader.grub.device = rootDisk; - - users.users.root.openssh.authorizedKeys.keys = [ - config.krebs.users.makefu-omo.pubkey - config.krebs.users.makefu-vbob.pubkey + boot.initrd.luks.devices = [ + { name = "luksroot"; + device = rootPart; + allowDiscards = true; + keyFileSize = 4096; + keyFile = "/dev/sdb"; + } ]; krebs.build.host = config.krebs.hosts.darth; From 06a65dd592a62663b15547796b6f11fddb205b31 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:03:32 +0200 Subject: [PATCH 18/41] ma 5pkgs: cleanup --- .../5pkgs/{ => custom}/alsa-tools/default.nix | 0 makefu/5pkgs/custom/default.nix | 3 ++ makefu/5pkgs/{ => custom}/qcma/default.nix | 5 +- makefu/5pkgs/default.nix | 11 ++-- makefu/5pkgs/dionaea/default.nix | 50 +++++++++++++++++++ makefu/5pkgs/farpd/default.nix | 2 +- makefu/5pkgs/libopencm3/default.nix | 30 +++++++++++ makefu/5pkgs/logstash-output-exec/default.nix | 32 ++++++++++++ makefu/5pkgs/mcomix/default.nix | 20 ++++++++ makefu/5pkgs/minibar/default.nix | 12 +++++ makefu/5pkgs/nltk/default.nix | 17 +++++++ makefu/5pkgs/novnc/default.nix | 1 - makefu/5pkgs/programs-db/default.nix | 12 +++++ 13 files changed, 186 insertions(+), 9 deletions(-) rename makefu/5pkgs/{ => custom}/alsa-tools/default.nix (100%) create mode 100644 makefu/5pkgs/custom/default.nix rename makefu/5pkgs/{ => custom}/qcma/default.nix (94%) create mode 100644 makefu/5pkgs/dionaea/default.nix create mode 100644 makefu/5pkgs/libopencm3/default.nix create mode 100644 makefu/5pkgs/logstash-output-exec/default.nix create mode 100644 makefu/5pkgs/mcomix/default.nix create mode 100644 makefu/5pkgs/minibar/default.nix create mode 100644 makefu/5pkgs/nltk/default.nix create mode 100644 makefu/5pkgs/programs-db/default.nix diff --git a/makefu/5pkgs/alsa-tools/default.nix b/makefu/5pkgs/custom/alsa-tools/default.nix similarity index 100% rename from makefu/5pkgs/alsa-tools/default.nix rename to makefu/5pkgs/custom/alsa-tools/default.nix diff --git a/makefu/5pkgs/custom/default.nix b/makefu/5pkgs/custom/default.nix new file mode 100644 index 000000000..626938cdc --- /dev/null +++ b/makefu/5pkgs/custom/default.nix @@ -0,0 +1,3 @@ +{}: +{ +} diff --git a/makefu/5pkgs/qcma/default.nix b/makefu/5pkgs/custom/qcma/default.nix similarity index 94% rename from makefu/5pkgs/qcma/default.nix rename to makefu/5pkgs/custom/qcma/default.nix index 6eb1a971d..d67cda142 100644 --- a/makefu/5pkgs/qcma/default.nix +++ b/makefu/5pkgs/custom/qcma/default.nix @@ -1,5 +1,5 @@ { lib, stdenv, fetchFromGitHub, fetchgit, libusb, libtool, autoconf, pkgconfig, git, -gettext, automake, libxml2 , qmakeHook, makeQtWrapper, +gettext, automake, libxml2 , qmake, qtbase, qttools, qtmultimedia, libnotify, ffmpeg, gdk_pixbuf }: let libvitamtp = stdenv.mkDerivation rec { @@ -52,13 +52,14 @@ in stdenv.mkDerivation rec { enableParallelBuilding = true; buildInputs = [ gdk_pixbuf ffmpeg libnotify libvitamtp git qtmultimedia qtbase ]; - nativeBuildInputs = [ qmakeHook qttools pkgconfig makeQtWrapper ]; + nativeBuildInputs = [ qmake qttools pkgconfig ]; meta = { description = "Content Manager Assistant for the PS Vita"; homepage = https://github.com/codestation/qcma; license = stdenv.lib.licenses.gpl2; platforms = stdenv.lib.platforms.linux; + broken = true; maintainers = with stdenv.lib.maintainers; [ makefu ]; }; } diff --git a/makefu/5pkgs/default.nix b/makefu/5pkgs/default.nix index bb776ef25..6070fc096 100644 --- a/makefu/5pkgs/default.nix +++ b/makefu/5pkgs/default.nix @@ -20,13 +20,14 @@ self: super: let (filterAttrs (_: eq "directory") (readDir path)); in { - alsa-hdspconf = callPackage ./alsa-tools { alsaToolTarget="hdspconf";}; - alsa-hdspmixer = callPackage ./alsa-tools { alsaToolTarget="hdspmixer";}; - alsa-hdsploader = callPackage ./alsa-tools { alsaToolTarget="hdsploader";}; + alsa-hdspconf = callPackage ./custom/alsa-tools { alsaToolTarget="hdspconf";}; + alsa-hdspmixer = callPackage ./custom/alsa-tools { alsaToolTarget="hdspmixer";}; + alsa-hdsploader = callPackage ./custom/alsa-tools { alsaToolTarget="hdsploader";}; + qcma = super.pkgs.libsForQt5.callPackage ./custom/qcma { }; inherit (callPackage ./devpi {}) devpi-web devpi-server devpi-client; - nodemcu-uploader = callPackage ./nodemcu-uploader {}; + nodemcu-uploader = super.pkgs.callPackage ./nodemcu-uploader {}; pwqgen-ger = callPackage { - wordset-file = pkgs.fetchurl { + wordset-file = super.pkgs.fetchurl { url = https://gist.githubusercontent.com/makefu/b56f5554c9ef03fe6e09878962e6fd8d/raw/1f147efec51325bc9f80c823bad8381d5b7252f6/wordset_4k.c ; sha256 = "18ddzyh11bywrhzdkzvrl7nvgp5gdb4k1s0zxbz2bkhd14vi72bb"; }; diff --git a/makefu/5pkgs/dionaea/default.nix b/makefu/5pkgs/dionaea/default.nix new file mode 100644 index 000000000..fef197c20 --- /dev/null +++ b/makefu/5pkgs/dionaea/default.nix @@ -0,0 +1,50 @@ +{ stdenv, lib, pkgs, fetchurl,fetchFromGitHub, + libpcap, libdnet, libevent, readline, autoconf, automake, libtool, zlib, pcre, + libev, + ... }: +let + liblcfg = stdenv.mkDerivation rec { + name = "liblcfg-${version}"; + version = "750bc90"; + src = fetchFromGitHub { + owner = "ThomasAdam"; + repo = "liblcfg"; + rev = version; + sha256 = "1k3r47p81paw5802jklx9xqbjrxr26pahipxn9nq3177qhxxibkr"; + }; + buildInputs = with pkgs;[ autoconf automake ]; + preConfigure = ''autoreconf -fi''; + sourceRoot = "${name}-src/code"; + }; +in stdenv.mkDerivation rec { + name = "liblcfg-${version}"; + + #version = "1.5c"; #original, does not compile due to libc errors + #src = fetchurl { + # url = "http://www.honeyd.org/uploads/honeyd-${version}.tar.gz"; + # sha256 = "0vcih16fk5pir5ssfil8x79nvi62faw0xvk8s5klnysv111db1ii"; + #}; + + #version = "64d087c"; # honeyd-1.6.7 + # sha256 = "0zhnn13r24y1q494xcfx64vyp84zqk8qmsl41fq2674230bn0p31"; + + version = "6756787f94c4f1ac53d1e5545d052774a0446c04"; + src = fetchFromGitHub { + owner = "rep"; + repo = "dionaea"; + rev = version; + sha256 = "04zjr9b7x0rqwzgb9gfxq6pclb817gz4qaghdl8xa79bqf9vv2p7"; + }; + + buildInputs = with pkgs;[ libtool automake autoconf ]; + configureFlags = [ + "--with-liblcfg=${liblcfg}" + "--with-libpcap=${libpcap}" + ]; + + meta = { + homepage = http://www.honeyd.org/; + description = "virtual Honeypots"; + license = lib.licenses.gpl2; + }; +} diff --git a/makefu/5pkgs/farpd/default.nix b/makefu/5pkgs/farpd/default.nix index d16400016..8dfcee90c 100644 --- a/makefu/5pkgs/farpd/default.nix +++ b/makefu/5pkgs/farpd/default.nix @@ -24,7 +24,7 @@ stdenv.mkDerivation rec { zlib coreutils python - pythonPackages.sqlite3 + pythonPackages.pysqlite ]; patches = [ ( fetchurl { diff --git a/makefu/5pkgs/libopencm3/default.nix b/makefu/5pkgs/libopencm3/default.nix new file mode 100644 index 000000000..ed35fc639 --- /dev/null +++ b/makefu/5pkgs/libopencm3/default.nix @@ -0,0 +1,30 @@ +{ lib, stdenv, fetchFromGitHub, gcc-arm-embedded, python }: +stdenv.mkDerivation rec { + name = "libopencm-${version}"; + version = "2017-04-01"; + + src = fetchFromGitHub { + owner = "libopencm3"; + repo = "libopencm3"; + rev = "383fafc862c0d47f30965f00409d03a328049278"; + sha256 = "0ar67icxl39cf7yb5glx3zd5413vcs7zp1jq0gzv1napvmrv3jv9"; + }; + + buildInputs = [ gcc-arm-embedded python ]; + buildPhase = '' + sed -i 's#/usr/bin/env python#${python}/bin/python#' ./scripts/irq2nvic_h + make + ''; + installPhase = '' + mkdir -p $out + cp -r lib $out/ + ''; + + meta = { + description = "Open Source ARM cortex m microcontroller library"; + homepage = https://github.com/libopencm3/libopencm3; + license = stdenv.lib.licenses.gpl2; + platforms = stdenv.lib.platforms.linux; + maintainers = with stdenv.lib.maintainers; [ makefu ]; + }; +} diff --git a/makefu/5pkgs/logstash-output-exec/default.nix b/makefu/5pkgs/logstash-output-exec/default.nix new file mode 100644 index 000000000..d1de851c7 --- /dev/null +++ b/makefu/5pkgs/logstash-output-exec/default.nix @@ -0,0 +1,32 @@ +{ pkgs, stdenv, lib, fetchFromGitHub }: + + +# TODO: requires ftw ruby package +stdenv.mkDerivation rec { + name = "logstash-input-github-${version}"; + version = "3.1.0"; + + src = fetchFromGitHub { + owner = "logstash-plugins"; + repo = "logstash-output-exec"; + rev = "v${version}"; + sha256 = "0ix5w9l6hrbjaymkh7fzymjvpkiias3hs0l77zdpcwdaa6cz53nf"; + }; + + dontBuild = true; + dontPatchELF = true; + dontStrip = true; + dontPatchShebangs = true; + installPhase = '' + mkdir -p $out/logstash + cp -r lib/* $out + ''; + + meta = with lib; { + description = "logstash output plugin"; + homepage = https://github.com/logstash-plugins/logstash-output-exec; + license = stdenv.lib.licenses.asl20; + platforms = stdenv.lib.platforms.unix; + maintainers = with maintainers; [ makefu ]; + }; +} diff --git a/makefu/5pkgs/mcomix/default.nix b/makefu/5pkgs/mcomix/default.nix new file mode 100644 index 000000000..a12e2e821 --- /dev/null +++ b/makefu/5pkgs/mcomix/default.nix @@ -0,0 +1,20 @@ +{ pkgs, lib ,python2Packages, fetchurl, gtk3}: +python2Packages.buildPythonPackage rec { + name = "mcomix-${version}"; + version = "1.2.1"; + + src = fetchurl { + url = "mirror://sourceforge/mcomix/${name}.tar.bz2"; + sha256 = "0fzsf9pklhfs1rzwzj64c0v30b74nk94p93h371rpg45qnfiahvy"; + }; + + propagatedBuildInputs = with python2Packages; + [ python2Packages.pygtk gtk3 python2Packages.pillow ]; + + meta = { + homepage = https://github.com/pyload/pyload; + description = "Free and Open Source download manager written in Python"; + license = lib.licenses.gpl3; + maintainers = with lib.maintainers; [ makefu ]; + }; +} diff --git a/makefu/5pkgs/minibar/default.nix b/makefu/5pkgs/minibar/default.nix new file mode 100644 index 000000000..384a73261 --- /dev/null +++ b/makefu/5pkgs/minibar/default.nix @@ -0,0 +1,12 @@ +{ lib, pkgs, fetchFromGitHub, ... }: + +with pkgs.python3Packages;buildPythonPackage rec { + name = "minibar-${version}"; + version = "0.5.0"; + src = fetchFromGitHub { + owner = "canassa"; + repo = "minibar"; + rev = "c8ecd61"; + sha256 = "1k718zrjd11rw93nmz2wxvhvsai6lwqfblnwjpmkpnslcdan7641"; + }; +} diff --git a/makefu/5pkgs/nltk/default.nix b/makefu/5pkgs/nltk/default.nix new file mode 100644 index 000000000..b2d88b3fe --- /dev/null +++ b/makefu/5pkgs/nltk/default.nix @@ -0,0 +1,17 @@ +{ lib, pkgs, fetchFromGitHub, ... }: + +with pkgs.pythonPackages;buildPythonPackage rec { + name = "nltk-${version}"; + version = "3.2.1"; + src = pkgs.fetchurl{ + #url = "mirror://pypi/n/${name}.tar.gz"; + url = "https://pypi.python.org/packages/58/85/8fa6f8c488507aab7d6234ce754bbbe61bfeb8382489785e2d764bf8f52a/${name}.tar.gz"; + sha256 = "0skxbhnymwlspjkzga0f7x1hg3y50fwpfghs8g8k7fh6f4nknlym"; + + }; + meta = { + homepage = http://nltk.org; + description = "Natural languages Toolkit"; + license = lib.licenses.asl20; + }; +} diff --git a/makefu/5pkgs/novnc/default.nix b/makefu/5pkgs/novnc/default.nix index b1d62248d..7da8e9be1 100644 --- a/makefu/5pkgs/novnc/default.nix +++ b/makefu/5pkgs/novnc/default.nix @@ -13,7 +13,6 @@ stdenv.mkDerivation rec { }; p = stdenv.lib.makeBinPath [ pkgs.nettools pkgs.python27Packages.websockify pkgs.coreutils pkgs.which pkgs.procps ]; - # TODO: propagatedBuildInputs does not seem to work with shell scripts patchPhase = '' sed -i '1aset -efu\nexport PATH=${p}\n' utils/launch.sh ''; diff --git a/makefu/5pkgs/programs-db/default.nix b/makefu/5pkgs/programs-db/default.nix new file mode 100644 index 000000000..f40b1b96e --- /dev/null +++ b/makefu/5pkgs/programs-db/default.nix @@ -0,0 +1,12 @@ +{ stdenv }: + +stdenv.mkDerivation rec { + name = "programs-db"; + src = builtins.fetchTarball https://nixos.org/channels/nixos-unstable/nixexprs.tar.xz ; + + phases = [ "unpackPhase" "installPhase" ]; + installPhase = '' + cp programs.sqlite $out + ''; + +} From f6d6bae25138349247946fea2bda167a368e4780 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:18:42 +0200 Subject: [PATCH 19/41] ma tools/dev: add gi --- makefu/2configs/tools/dev.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/makefu/2configs/tools/dev.nix b/makefu/2configs/tools/dev.nix index 42006eb22..6681484fd 100644 --- a/makefu/2configs/tools/dev.nix +++ b/makefu/2configs/tools/dev.nix @@ -1,9 +1,10 @@ { pkgs, ... }: { - krebs.per-user.makefu.packages = with pkgs;[ + users.users.makefu.packages = with pkgs;[ python35Packages.virtualenv # embedded + gi flashrom mosquitto libcoap From d994a3ec26a20020dd470667ab87e4ded93afd68 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:18:06 +0200 Subject: [PATCH 20/41] ma hw/tp-x230: enable rngd again this works for the vanilla firmware but not on coreboot --- makefu/2configs/hw/tp-x230.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/makefu/2configs/hw/tp-x230.nix b/makefu/2configs/hw/tp-x230.nix index c705b52a7..14572b35c 100644 --- a/makefu/2configs/hw/tp-x230.nix +++ b/makefu/2configs/hw/tp-x230.nix @@ -33,8 +33,8 @@ with import ; Option "Backlight" "intel_backlight" ''; }; - # no entropy source working - # security.rngd.enable = true; + + security.rngd.enable = true; services.xserver.displayManager.sessionCommands ='' xinput set-int-prop "TPPS/2 IBM TrackPoint" "Evdev Wheel Emulation" 8 1 From b4d1a357c4e7df2f40a695bdab269115b4887870 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:17:19 +0200 Subject: [PATCH 21/41] ma share/gum: fix download user --- makefu/2configs/share/gum.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/makefu/2configs/share/gum.nix b/makefu/2configs/share/gum.nix index e578f43d3..f5942a0f7 100644 --- a/makefu/2configs/share/gum.nix +++ b/makefu/2configs/share/gum.nix @@ -1,6 +1,6 @@ { config, lib, pkgs, ... }: -with config.krebs.lib; +with import ; let hostname = config.krebs.build.host.name; in { @@ -11,7 +11,7 @@ in { # home = "/var/empty"; # }; - users.users.download = { }; + users.users.download.uid = genid "download"; services.samba = { enable = true; shares = { From 512869d4e3257a06115c09b67538cebf543c6c52 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:16:59 +0200 Subject: [PATCH 22/41] ma anon-ftp: replace ftpdir --- makefu/2configs/share/anon-ftp.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/makefu/2configs/share/anon-ftp.nix b/makefu/2configs/share/anon-ftp.nix index 471f22cba..d2a535f97 100644 --- a/makefu/2configs/share/anon-ftp.nix +++ b/makefu/2configs/share/anon-ftp.nix @@ -1,6 +1,6 @@ { config, lib, ... }: let - ftpdir = "/home/ftp"; + ftpdir = "/data"; in { networking.firewall = { allowedTCPPorts = [ 20 21 ]; From 94bec25995287c4eee65924c3e6794b6333aeca6 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:16:39 +0200 Subject: [PATCH 23/41] ma sda-crypto-root: add notes for formatting the harddrive --- makefu/2configs/fs/sda-crypto-root.nix | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/makefu/2configs/fs/sda-crypto-root.nix b/makefu/2configs/fs/sda-crypto-root.nix index cfa703aaf..55cfd74f5 100644 --- a/makefu/2configs/fs/sda-crypto-root.nix +++ b/makefu/2configs/fs/sda-crypto-root.nix @@ -4,6 +4,12 @@ # sda1: boot ext4 (label nixboot) - must be unlocked on boot if required: # boot.initrd.luks.devices = [ { name = "luksroot"; device = "/dev/sda2"; allowDiscards=true; }]; # sda2: cryptoluks -> ext4 + +# fdisk /dev/sda + # boot 500M + # rest rest +# cryptsetup luksFormat /dev/sda2 +# with import ; { boot = { From c84615a0315cc285c25b52ed1785e057f2535168 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:15:52 +0200 Subject: [PATCH 24/41] ma elchos/search: refactor dyndns code --- makefu/2configs/elchos/search.nix | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/makefu/2configs/elchos/search.nix b/makefu/2configs/elchos/search.nix index 5777be373..521bfc80a 100644 --- a/makefu/2configs/elchos/search.nix +++ b/makefu/2configs/elchos/search.nix @@ -23,10 +23,21 @@ let pid=${ddclientPIDFile} ${concatStringsSep "\n" (mapAttrsToList (user: pass: '' + protocol=dyndns2 use=if, if=${primary-itf} - protocol=dyndns2, server=ipv4.nsupdate.info, login=${user}, password='${pass}' ${user} - #usev6=if, if=${primary-itf} - #protocol=dyndns2, server=ipv6.nsupdate.info, login=${user}, password='${pass}' ${user} + ssl=yes + server=ipv4.nsupdate.info + login=${user} + password='${pass}' + ${user} + + protocol=dyndns2 + usev5=if, if=${primary-itf} + ssl=yes + server=ipv6.nsupdate.info + login=${user} + password='${pass}' + ${user} '') dict)} ''; From efb0ea1ab63db828bafb905acee13571a905c639 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:15:06 +0200 Subject: [PATCH 25/41] ma backup: add placeholder for wolf backup --- makefu/2configs/backup.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/makefu/2configs/backup.nix b/makefu/2configs/backup.nix index 1cc78bfc1..166365ba0 100644 --- a/makefu/2configs/backup.nix +++ b/makefu/2configs/backup.nix @@ -31,6 +31,7 @@ in { krebs.backup.plans = { # wry-to-omo_root = defaultPull config.krebs.hosts.wry "/"; gum-to-omo_root = defaultPull config.krebs.hosts.gum "/"; + # wolf-to-omo_root = defaultPull config.krebs.hosts.wolf "/"; }; environment.systemPackages = [ pkgs.borgbackup From 842c62e6cd12df0fbbfe3ceda00242e366009cb4 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:14:30 +0200 Subject: [PATCH 26/41] ma jack-on-pulse: depend on sound.target --- makefu/2configs/audio/jack-on-pulse.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/makefu/2configs/audio/jack-on-pulse.nix b/makefu/2configs/audio/jack-on-pulse.nix index a8ee05c7d..e18b2192a 100644 --- a/makefu/2configs/audio/jack-on-pulse.nix +++ b/makefu/2configs/audio/jack-on-pulse.nix @@ -45,7 +45,7 @@ in Restart = "always"; RestartSec = "5"; }; - # after = [ "display-manager.service" "sound.target" ]; + after = [ "display-manager.service" "sound.target" ]; wantedBy = [ "default.target" ]; }; }; From edb24e8d7ca7028217f4eebd0354e2f48ec2ef22 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:14:00 +0200 Subject: [PATCH 27/41] ma x: allow virtualbox firewall --- makefu/1systems/x/config.nix | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/makefu/1systems/x/config.nix b/makefu/1systems/x/config.nix index 368655575..8e8c8a736 100644 --- a/makefu/1systems/x/config.nix +++ b/makefu/1systems/x/config.nix @@ -42,6 +42,14 @@ with import ; + { + networking.firewall.allowedTCPPorts = [ 8080 ]; + networking.nat = { + enable = true; + externalInterface = "wlp3s0"; + internalInterfaces = [ "vboxnet0" ]; + }; + } # Services @@ -81,6 +89,7 @@ with import ; networking.firewall.enable = true; networking.firewall.allowedTCPPorts = [ 80 24800 26061 8000 3000 ]; networking.firewall.allowedUDPPorts = [ 665 26061 ]; + networking.firewall.trustedInterfaces = [ "vboxnet0" ]; krebs.build.host = config.krebs.hosts.x; From 94f7791024b658556e950603846035eacc3e3337 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:12:27 +0200 Subject: [PATCH 28/41] ma tools: add jdk and jre to android packages --- makefu/2configs/tools/android-pentest.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/makefu/2configs/tools/android-pentest.nix b/makefu/2configs/tools/android-pentest.nix index 3f65424cc..da8a357ae 100644 --- a/makefu/2configs/tools/android-pentest.nix +++ b/makefu/2configs/tools/android-pentest.nix @@ -10,5 +10,8 @@ apktool jd-gui android-studio + jdk + jre + openssl ]; } From efa73b9e9a557ce711b8ef32d034d69972a4758a Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:11:24 +0200 Subject: [PATCH 29/41] ma urlwatch: github-rss --- makefu/2configs/urlwatch/default.nix | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/makefu/2configs/urlwatch/default.nix b/makefu/2configs/urlwatch/default.nix index f17bcdc3a..47b5d7fc3 100644 --- a/makefu/2configs/urlwatch/default.nix +++ b/makefu/2configs/urlwatch/default.nix @@ -1,6 +1,11 @@ { config, lib, ... }: -{ +let + grss = name: { #github rss feed + url = "https://github.com/${name}/releases.atom"; + filter = "grepi:( Date: Wed, 16 Aug 2017 12:10:55 +0200 Subject: [PATCH 30/41] ma vim: show tabs --- makefu/2configs/vim.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/makefu/2configs/vim.nix b/makefu/2configs/vim.nix index 227d73c81..524caf8f5 100644 --- a/makefu/2configs/vim.nix +++ b/makefu/2configs/vim.nix @@ -21,6 +21,9 @@ in { vimrcConfig.customRC = '' set nocompatible syntax on + set list + set listchars=tab:▸ + "set list listchars=tab:>-,trail:.,extends:> filetype off filetype plugin indent on From 583c8b6b4ef588874bc5efbbaff07b0cf2e84b75 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:09:59 +0200 Subject: [PATCH 31/41] ma docker: add dockertools to systemPackages --- makefu/2configs/virtualisation/docker.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/makefu/2configs/virtualisation/docker.nix b/makefu/2configs/virtualisation/docker.nix index 98fd980cc..ddef9e371 100644 --- a/makefu/2configs/virtualisation/docker.nix +++ b/makefu/2configs/virtualisation/docker.nix @@ -1,4 +1,8 @@ -{...}: +{ pkgs, ... }: { virtualisation.docker.enable = true; + environment.systemPackages = with pkgs;[ + docker + docker_compose + ]; } From da17fa410386eb7aed50d3f9db61cb6e8c32582d Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:09:18 +0200 Subject: [PATCH 32/41] ma gum: un-hardcode interface --- makefu/1systems/gum/config.nix | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/makefu/1systems/gum/config.nix b/makefu/1systems/gum/config.nix index bbb8cfe11..110edc130 100644 --- a/makefu/1systems/gum/config.nix +++ b/makefu/1systems/gum/config.nix @@ -9,6 +9,7 @@ let external-gw6 = "fe80::1"; external-netmask = 22; external-netmask6 = 64; + ext-if = "et0"; # gets renamed on the fly internal-ip = config.krebs.build.host.nets.retiolum.ip4.addr; main-disk = "/dev/disk/by-id/scsi-0QEMU_QEMU_HARDDISK_drive-scsi0-0-0-0"; in { @@ -41,6 +42,7 @@ in { + ## Web @@ -94,7 +96,7 @@ in { ]; }; - + makefu.server.primary-itf = ext-if; # access users.users = { @@ -120,7 +122,7 @@ in { # Network services.udev.extraRules = '' - SUBSYSTEM=="net", ATTR{address}=="${external-mac}", NAME="et0" + SUBSYSTEM=="net", ATTR{address}=="${external-mac}", NAME="${ext-if}" ''; boot.kernelParams = [ ]; networking = { @@ -152,14 +154,16 @@ in { 21032 ]; }; - interfaces.et0.ip4 = [{ - address = external-ip; - prefixLength = external-netmask; - }]; - interfaces.et0.ip6 = [{ - address = external-ip6; - prefixLength = external-netmask6; - }]; + interfaces."${ext-if}" = { + ip4 = [{ + address = external-ip; + prefixLength = external-netmask; + }]; + ip6 = [{ + address = external-ip6; + prefixLength = external-netmask6; + }]; + }; defaultGateway6 = external-gw6; defaultGateway = external-gw; nameservers = [ "8.8.8.8" ]; From a795766f3a881d43f92dcafcf26eeb765e993ed7 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 12:08:14 +0200 Subject: [PATCH 33/41] ma configs/default: add vim as default --- krebs/2configs/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/krebs/2configs/default.nix b/krebs/2configs/default.nix index daf9bd9d0..e7ece87b6 100644 --- a/krebs/2configs/default.nix +++ b/krebs/2configs/default.nix @@ -22,6 +22,7 @@ with import ; environment.systemPackages = with pkgs; [ git + vim rxvt_unicode.terminfo ]; From 445d4f74c225dcc44846488e4d30c0b8e4e52bd9 Mon Sep 17 00:00:00 2001 From: lassulus Date: Wed, 16 Aug 2017 13:35:30 +0200 Subject: [PATCH 34/41] l skynet.r: don't suspend on lid close --- lass/1systems/skynet/config.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lass/1systems/skynet/config.nix b/lass/1systems/skynet/config.nix index b707f4388..0b9499982 100644 --- a/lass/1systems/skynet/config.nix +++ b/lass/1systems/skynet/config.nix @@ -44,6 +44,10 @@ with import ; krebs.build.host = config.krebs.hosts.skynet; + services.logind.extraConfig = '' + HandleLidSwitch=ignore + ''; + #fileSystems = { # "/bku" = { # device = "/dev/mapper/pool-bku"; From d94f85a18cdcece49e3b95542567d8b1023f0da1 Mon Sep 17 00:00:00 2001 From: makefu Date: Wed, 16 Aug 2017 22:03:48 +0200 Subject: [PATCH 35/41] ma pkgs: init inkscape --- makefu/5pkgs/custom/inkscape/dxf_fix.patch | 13 +++++++++++++ makefu/5pkgs/default.nix | 3 +++ 2 files changed, 16 insertions(+) create mode 100644 makefu/5pkgs/custom/inkscape/dxf_fix.patch diff --git a/makefu/5pkgs/custom/inkscape/dxf_fix.patch b/makefu/5pkgs/custom/inkscape/dxf_fix.patch new file mode 100644 index 000000000..5ea0a073e --- /dev/null +++ b/makefu/5pkgs/custom/inkscape/dxf_fix.patch @@ -0,0 +1,13 @@ +--- ./share/extensions/dxf_outlines.py 2017-02-14 00:46:57.000000000 +0100 ++++ ./share/extensions/dxf_outlines.py.new 2017-05-10 04:15:03.000000000 +0200 +@@ -340,7 +340,7 @@ + scale = eval(self.options.units) + if not scale: + scale = 25.4/96 # if no scale is specified, assume inch as baseunit +- h = self.unittouu(self.document.getroot().xpath('@height', namespaces=inkex.NSS)[0]) ++ h = self.unittouu(self.getDocumentHeight()) + self.groupmat = [[[scale, 0.0, 0.0], [0.0, -scale, h*scale]]] + doc = self.document.getroot() + self.process_group(doc) + + diff --git a/makefu/5pkgs/default.nix b/makefu/5pkgs/default.nix index 6070fc096..96975e54f 100644 --- a/makefu/5pkgs/default.nix +++ b/makefu/5pkgs/default.nix @@ -26,6 +26,9 @@ in { qcma = super.pkgs.libsForQt5.callPackage ./custom/qcma { }; inherit (callPackage ./devpi {}) devpi-web devpi-server devpi-client; nodemcu-uploader = super.pkgs.callPackage ./nodemcu-uploader {}; + inkscape = super.pkgs.stdenv.lib.overrideDerivation super.inkscape (old: { + patches = [ ./custom/inkscape/dxf_fix.patch ]; + }); pwqgen-ger = callPackage { wordset-file = super.pkgs.fetchurl { url = https://gist.githubusercontent.com/makefu/b56f5554c9ef03fe6e09878962e6fd8d/raw/1f147efec51325bc9f80c823bad8381d5b7252f6/wordset_4k.c ; From a70fc9b95abf47aca54d39076529b3718adeb7cc Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 21 Aug 2017 12:36:04 +0200 Subject: [PATCH 36/41] l: mors <-> daedalus --- lass/1systems/daedalus/config.nix | 6 +++--- lass/1systems/mors/config.nix | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/lass/1systems/daedalus/config.nix b/lass/1systems/daedalus/config.nix index 290d8a780..72a45a3d9 100644 --- a/lass/1systems/daedalus/config.nix +++ b/lass/1systems/daedalus/config.nix @@ -4,7 +4,7 @@ imports = [ - + @@ -29,7 +29,7 @@ }; services.udev.extraRules = '' - SUBSYSTEM=="net", ATTR{address}=="00:24:d7:f0:e8:c8", NAME="wl0" - SUBSYSTEM=="net", ATTR{address}=="f0:de:f1:8f:8a:78", NAME="et0" + SUBSYSTEM=="net", ATTR{address}=="08:11:96:0a:5d:6c", NAME="wl0" + SUBSYSTEM=="net", ATTR{address}=="f0:de:f1:71:cb:35", NAME="et0" ''; } diff --git a/lass/1systems/mors/config.nix b/lass/1systems/mors/config.nix index 5bc52d633..bb6f84c7b 100644 --- a/lass/1systems/mors/config.nix +++ b/lass/1systems/mors/config.nix @@ -5,7 +5,7 @@ with import ; imports = [ - + @@ -104,8 +104,8 @@ with import ; }; services.udev.extraRules = '' - SUBSYSTEM=="net", ATTR{address}=="08:11:96:0a:5d:6c", NAME="wl0" - SUBSYSTEM=="net", ATTR{address}=="f0:de:f1:71:cb:35", NAME="et0" + SUBSYSTEM=="net", ATTR{address}=="00:24:d7:f0:e8:c8", NAME="wl0" + SUBSYSTEM=="net", ATTR{address}=="f0:de:f1:8f:8a:78", NAME="et0" ''; #TODO activationScripts seem broken, fix them! From 51cb5bb1f10aaf68499f6fbe53923959d35f039b Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 21 Aug 2017 12:37:57 +0200 Subject: [PATCH 37/41] l daedalus.r: add kde desktop --- lass/1systems/daedalus/config.nix | 68 +++++++++++++++++++++++++++---- 1 file changed, 60 insertions(+), 8 deletions(-) diff --git a/lass/1systems/daedalus/config.nix b/lass/1systems/daedalus/config.nix index 72a45a3d9..36daea1d5 100644 --- a/lass/1systems/daedalus/config.nix +++ b/lass/1systems/daedalus/config.nix @@ -1,3 +1,4 @@ +with import ; { config, pkgs, ... }: { @@ -6,18 +7,69 @@ - - - - - - - - + { + # bubsy config + users.users.bubsy = { + uid = genid "bubsy"; + home = "/home/bubsy"; + group = "users"; + createHome = true; + extraGroups = [ + "audio" + "networkmanager" + ]; + useDefaultShell = true; + }; + networking.networkmanager.enable = true; + networking.wireless.enable = mkForce false; + hardware.pulseaudio = { + enable = true; + systemWide = true; + }; + environment.systemPackages = with pkgs; [ + pavucontrol + firefox + hexchat + networkmanagerapplet + ]; + services.xserver.enable = true; + services.xserver.displayManager.lightdm.enable = true; + services.xserver.desktopManager.plasma5.enable = true; + } + { + krebs.per-user.bitcoin.packages = [ + pkgs.electrum + ]; + users.extraUsers = { + bitcoin = { + name = "bitcoin"; + description = "user for bitcoin stuff"; + home = "/home/bitcoin"; + useDefaultShell = true; + createHome = true; + }; + }; + security.sudo.extraConfig = '' + bubsy ALL=(bitcoin) NOPASSWD: ALL + ''; + } ]; + time.timeZone = "Europe/Berlin"; + + hardware.trackpoint = { + enable = true; + sensitivity = 220; + speed = 0; + emulateWheel = true; + }; + + services.logind.extraConfig = '' + HandleLidSwitch=ignore + ''; + krebs.build.host = config.krebs.hosts.daedalus; fileSystems = { From bbc966fc7bcee828af7c0023ca3c6e63c625174f Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 21 Aug 2017 12:40:29 +0200 Subject: [PATCH 38/41] l git: allow hooks to be set individually --- lass/2configs/git.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lass/2configs/git.nix b/lass/2configs/git.nix index d3f5d1f39..eb606037e 100644 --- a/lass/2configs/git.nix +++ b/lass/2configs/git.nix @@ -80,7 +80,7 @@ let public = true; }; - make-restricted-repo = name: { collaborators ? [], announce ? false, ... }: { + make-restricted-repo = name: { collaborators ? [], announce ? false, hooks ? {}, ... }: { inherit collaborators name; public = false; hooks = optionalAttrs announce { @@ -93,7 +93,7 @@ let # TODO define branches in some kind of option per repo branches = [ "master" "staging*" ]; }; - }; + } // hooks; }; make-rules = From 2306996b10e1a750cc098e07ed7f21f6990bc24b Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 21 Aug 2017 12:49:29 +0200 Subject: [PATCH 39/41] l pkgs.xmonad: bind brainmenu to M-o --- lass/5pkgs/xmonad-lass.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/lass/5pkgs/xmonad-lass.nix b/lass/5pkgs/xmonad-lass.nix index 22ec7efa9..38a9550df 100644 --- a/lass/5pkgs/xmonad-lass.nix +++ b/lass/5pkgs/xmonad-lass.nix @@ -98,6 +98,7 @@ myKeyMap = [ ("M4-", spawn "${pkgs.i3lock}/bin/i3lock -i /var/lib/wallpaper/wallpaper -f") , ("M4-C-p", spawn "${pkgs.scrot}/bin/scrot ~/public_html/scrot.png") , ("M4-p", spawn "${pkgs.pass}/bin/passmenu --type") + , ("M4-o", spawn "${pkgs.brain}/bin/brainmenu --type") , ("", spawn "${pkgs.pulseaudioLight.out}/bin/pactl -- set-sink-volume @DEFAULT_SINK@ +4%") , ("", spawn "${pkgs.pulseaudioLight.out}/bin/pactl -- set-sink-volume @DEFAULT_SINK@ -4%") , ("", spawn "${pkgs.xorg.xbacklight}/bin/xbacklight -time 0 -dec 1%") From 6a9e241df642e5b6b21d264719c52b29d577ff42 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 21 Aug 2017 12:57:36 +0200 Subject: [PATCH 40/41] l baseX: add gi to pkgs --- lass/2configs/baseX.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/lass/2configs/baseX.nix b/lass/2configs/baseX.nix index 86d0ac7c1..3a99e65a0 100644 --- a/lass/2configs/baseX.nix +++ b/lass/2configs/baseX.nix @@ -48,6 +48,7 @@ in { acpi dic dmenu + gi gitAndTools.qgit lm_sensors haskellPackages.hledger From fd6b42355907de5313ea3576e5d1bfa549433099 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 21 Aug 2017 18:41:15 +0200 Subject: [PATCH 41/41] nixpkgs: 0590ecb -> 51a8326 --- krebs/source.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/krebs/source.nix b/krebs/source.nix index db30e1e35..400826351 100644 --- a/krebs/source.nix +++ b/krebs/source.nix @@ -14,6 +14,6 @@ in stockholm.file = toString ; nixpkgs.git = { url = https://github.com/NixOS/nixpkgs; - ref = "0590ecbe9e6b9a076065be29370701da758c61f1"; # nixos-17.03 @ 2017-07-30 + ref = "51a83266d164195698f04468d90d2c6238ed3491"; # nixos-17.03 @ 2017-07-30 }; }