summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--krebs/3modules/lass/default.nix8
-rw-r--r--krebs/5pkgs/test/infest-cac-centos7/default.nix5
-rw-r--r--lass/1systems/helios.nix11
-rw-r--r--lass/1systems/mors.nix19
-rw-r--r--lass/1systems/prism.nix11
-rw-r--r--lass/1systems/uriel.nix9
-rw-r--r--lass/2configs/base.nix7
-rw-r--r--lass/2configs/browsers.nix13
-rw-r--r--lass/2configs/retiolum.nix2
-rw-r--r--lass/2configs/weechat.nix13
-rw-r--r--lass/3modules/newsbot-js.nix2
-rw-r--r--makefu/1systems/omo.nix1
-rw-r--r--makefu/2configs/git/brain-retiolum.nix1
-rw-r--r--makefu/2configs/git/cgit-retiolum.nix2
-rw-r--r--makefu/2configs/laptop-utils.nix62
-rw-r--r--makefu/2configs/mail-client.nix2
-rw-r--r--makefu/2configs/main-laptop.nix12
-rw-r--r--makefu/5pkgs/default.nix3
-rw-r--r--makefu/5pkgs/nodemcu-uploader/default.nix22
19 files changed, 145 insertions, 60 deletions
diff --git a/krebs/3modules/lass/default.nix b/krebs/3modules/lass/default.nix
index 4bf10ac5..6220a2d6 100644
--- a/krebs/3modules/lass/default.nix
+++ b/krebs/3modules/lass/default.nix
@@ -19,6 +19,7 @@ with config.krebs.lib;
addrs6 = ["42:0000:0000:0000:0000:0000:d15f:1233"];
aliases = [
"dishfire.retiolum"
+ "dishfire.r"
];
tinc.pubkey = ''
-----BEGIN RSA PUBLIC KEY-----
@@ -52,6 +53,7 @@ with config.krebs.lib;
"echelon.retiolum"
"cgit.echelon.retiolum"
"go.retiolum"
+ "go.r"
];
tinc.pubkey = ''
-----BEGIN RSA PUBLIC KEY-----
@@ -83,6 +85,7 @@ with config.krebs.lib;
addrs6 = ["42:0000:0000:0000:0000:0000:0000:15ab"];
aliases = [
"prism.retiolum"
+ "prism.r"
"cgit.prism.retiolum"
];
tinc.pubkey = ''
@@ -114,6 +117,7 @@ with config.krebs.lib;
addrs6 = ["42:422a:194f:ff3b:e196:2f82:5cf5:bc00"];
aliases = [
"fastpoke.retiolum"
+ "fastpoke.r"
"cgit.fastpoke.retiolum"
];
tinc.pubkey = ''
@@ -144,6 +148,7 @@ with config.krebs.lib;
addrs6 = ["42:941e:2816:35f4:5c5e:206b:3f0b:f762"];
aliases = [
"cloudkrebs.retiolum"
+ "cloudkrebs.r"
"cgit.cloudkrebs.retiolum"
];
tinc.pubkey = ''
@@ -173,6 +178,7 @@ with config.krebs.lib;
addrs6 = ["42:dc25:60cf:94ef:759b:d2b6:98a9:2e56"];
aliases = [
"uriel.retiolum"
+ "uriel.r"
"cgit.uriel.retiolum"
];
tinc.pubkey = ''
@@ -203,6 +209,7 @@ with config.krebs.lib;
addrs6 = ["42:0:0:0:0:0:0:dea7"];
aliases = [
"mors.retiolum"
+ "mors.r"
"cgit.mors.retiolum"
];
tinc.pubkey = ''
@@ -229,6 +236,7 @@ with config.krebs.lib;
addrs6 = ["42:0:0:0:0:0:0:7105"];
aliases = [
"helios.retiolum"
+ "helios.r"
"cgit.helios.retiolum"
];
tinc.pubkey = ''
diff --git a/krebs/5pkgs/test/infest-cac-centos7/default.nix b/krebs/5pkgs/test/infest-cac-centos7/default.nix
index 3be4b1c4..f5fe8482 100644
--- a/krebs/5pkgs/test/infest-cac-centos7/default.nix
+++ b/krebs/5pkgs/test/infest-cac-centos7/default.nix
@@ -1,4 +1,6 @@
-{ stdenv, coreutils,makeWrapper, cac-api, cac-cert, cac-panel, gnumake, gnused, jq, openssh, ... }:
+{ stdenv, coreutils, makeWrapper,
+ cac-api, cac-cert, cac-panel, gnumake, gnused, jq, openssh, sshpass,
+ ... }:
stdenv.mkDerivation rec {
name = "${shortname}-${version}";
@@ -21,6 +23,7 @@ stdenv.mkDerivation rec {
gnused
jq
openssh
+ sshpass
];
installPhase = ''
diff --git a/lass/1systems/helios.nix b/lass/1systems/helios.nix
index 0103b6ec..2784375c 100644
--- a/lass/1systems/helios.nix
+++ b/lass/1systems/helios.nix
@@ -19,12 +19,11 @@ with builtins;
# };
#}
{
- krebs.iptables = {
- tables = {
- filter.INPUT.rules = [
- { predicate = "-p tcp --dport 8000"; target = "ACCEPT"; precedence = 9001; }
- ];
- };
+ services.elasticsearch = {
+ enable = true;
+ plugins = [
+ pkgs.elasticsearchPlugins.elasticsearch_kopf
+ ];
};
}
];
diff --git a/lass/1systems/mors.nix b/lass/1systems/mors.nix
index 9f492e2c..dc09c9d3 100644
--- a/lass/1systems/mors.nix
+++ b/lass/1systems/mors.nix
@@ -270,14 +270,14 @@
emulateWheel = true;
};
- services.xserver = {
- videoDriver = "intel";
- vaapiDrivers = [ pkgs.vaapiIntel ];
- deviceSection = ''
- Option "AccelMethod" "sna"
- BusID "PCI:0:2:0"
- '';
- };
+ #services.xserver = {
+ # videoDriver = "intel";
+ # vaapiDrivers = [ pkgs.vaapiIntel ];
+ # deviceSection = ''
+ # Option "AccelMethod" "sna"
+ # BusID "PCI:0:2:0"
+ # '';
+ #};
environment.systemPackages = with pkgs; [
cac-api
@@ -328,7 +328,4 @@
tapButtons = false;
twoFingerScroll = true;
};
-
- #for google hangout
- users.extraUsers.gm.extraGroups = [ "audio" "video" ];
}
diff --git a/lass/1systems/prism.nix b/lass/1systems/prism.nix
index 05b3470e..864e59b2 100644
--- a/lass/1systems/prism.nix
+++ b/lass/1systems/prism.nix
@@ -83,10 +83,10 @@ in {
{
sound.enable = false;
}
- {
- #workaround for server dying after 6-7h
- boot.kernelPackages = pkgs.linuxPackages_4_2;
- }
+ #{
+ # #workaround for server dying after 6-7h
+ # boot.kernelPackages = pkgs.linuxPackages_4_2;
+ #}
{
nixpkgs.config.allowUnfree = true;
}
@@ -119,7 +119,8 @@ in {
}
{
users.users.chat.openssh.authorizedKeys.keys = [
- "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDJJKlOeAHyi7lToCqRF/hdA2TrtVbrTUd2ayuWsXe9JWiyeyKH/LNY3SrgxCWPZSItE9VK68ghMuVYK/A8IAcgzNhzFYLDxmtsidjiOJBj2ZGsjqevoQ5HuKB/pob8CLW3dr1Rx38Any/XXxpfeO6vemCJMGLTe5gSlrCI+Tk1qNt0Rz+rke73Hwt9wW39g8X3prF2q9ryL9OFCcsoYUE7PIOV9xM1GaDFfTR4bKux7HyFKmG+rBvmJHB5OPW8UAtVZGY/FIChwlmF6QNO5Zym497bG1RCOGplaLpRXVJrmoUkZUO7EazePPxIjz2duWYqFtwl5R9YGy1+a+F58G19DS7wJHM29td117/ZANjRTxE5q/aJm2okJYOVSqhYzdhji+BWVZ5ai7cktpAdtPo++yiZN90LvogXNB64kFxVGuX52xZcA3KLKmvrd47o9k0pzO+oCoArxPFIx0YkHfy/yw7OG8Z+KLK8l9WXWBZO5TpjcydnEcRZ8OEqVhtmDh+9h1zhPphuFBtT1JPbt8m132RUy23qsNRtZ/lnnfQbrxgHPRzVuvA8o4ahOEUdvV9SYnzKb6qMFXGp25EhlcWnR4/toyG6I3paBtByeHkaxjgCuvm9Hob6f/xFr3kEJ4WXTVguyrcFgNg2EcEfdkrTMhNn9OIHEFFQ8whIBv5jlw== JuiceSSH"
+ "ecdsa-sha2-nistp521 AAAAE2VjZHNhLXNoYTItbmlzdHA1MjEAAAAIbmlzdHA1MjEAAACFBAFhFJUMTfPbv3SzqlT9S67Av/m/ctLfTd3mMhD4O9hZc+t+dZmaHWj3v1KujzMBiDp3Yfo2YdVVZLTwTluHD8yNoQH418Vm01nrYHwOsc5J0br3mb0URZSstPiz6/6Fc+PNCDfQ2skUAWUidWiH+JolROFQ4y2lfpLOw+wsK2jj+Gqx6w== JuiceSSH"
+ config.krebs.users.lass-uriel.pubkey
];
}
{
diff --git a/lass/1systems/uriel.nix b/lass/1systems/uriel.nix
index 0758164f..4e4eca21 100644
--- a/lass/1systems/uriel.nix
+++ b/lass/1systems/uriel.nix
@@ -15,15 +15,6 @@ with builtins;
../2configs/bitlbee.nix
../2configs/weechat.nix
../2configs/skype.nix
- {
- users.extraUsers = {
- root = {
- openssh.authorizedKeys.keys = map readFile [
- ../../krebs/Zpubkeys/uriel.ssh.pub
- ];
- };
- };
- }
];
krebs.build.host = config.krebs.hosts.uriel;
diff --git a/lass/2configs/base.nix b/lass/2configs/base.nix
index d2c96fda..53983175 100644
--- a/lass/2configs/base.nix
+++ b/lass/2configs/base.nix
@@ -54,8 +54,8 @@ with config.krebs.lib;
#secrets-common = "/home/lass/secrets/common";
stockholm = "/home/lass/stockholm";
nixpkgs = {
- url = https://github.com/Lassulus/nixpkgs;
- rev = "d0e3cca04edd5d1b3d61f188b4a5f61f35cdf1ce";
+ url = https://github.com/NixOS/nixpkgs;
+ rev = "885acea1dd82b0354ff2b6bcf1268b3031cf93df";
dev = "/home/lass/src/nixpkgs";
};
} // optionalAttrs config.krebs.build.host.secure {
@@ -104,6 +104,9 @@ with config.krebs.lib;
#stuff for dl
aria2
+
+ #neat utils
+ krebspaste
];
programs.bash = {
diff --git a/lass/2configs/browsers.nix b/lass/2configs/browsers.nix
index eb764068..47a16d4c 100644
--- a/lass/2configs/browsers.nix
+++ b/lass/2configs/browsers.nix
@@ -1,6 +1,8 @@
{ config, lib, pkgs, ... }:
let
+ inherit (config.krebs.lib) genid;
+
mainUser = config.users.extraUsers.mainUser;
createChromiumUser = name: extraGroups: packages:
{
@@ -8,6 +10,7 @@ let
inherit name;
inherit extraGroups;
home = "/home/${name}";
+ uid = genid name;
useDefaultShell = true;
createHome = true;
};
@@ -28,6 +31,7 @@ let
inherit name;
inherit extraGroups;
home = "/home/${name}";
+ uid = genid name;
useDefaultShell = true;
createHome = true;
};
@@ -48,16 +52,17 @@ in {
environment.systemPackages = [
(pkgs.writeScriptBin "browser-select" ''
- BROWSER=$(echo -e "ff\ncr\nfb\ngm\nflash" | dmenu)
+ BROWSER=$(echo -e "ff\ncr\nwk\nfb\ngm\nflash" | dmenu)
$BROWSER $@
'')
];
imports = [
- ( createFirefoxUser "ff" [ "audio" ] [ ] )
+ ( createFirefoxUser "ff" [ "audio" ] [ pkgs.firefox ] )
( createChromiumUser "cr" [ "audio" ] [ pkgs.chromium ] )
- ( createChromiumUser "fb" [ ] [ pkgs.chromium ] )
- ( createChromiumUser "gm" [ ] [ pkgs.chromium ] )
+ ( createChromiumUser "wk" [ "audio" ] [ pkgs.chromium ] )
+ ( createChromiumUser "fb" [ "audio" ] [ pkgs.chromium ] )
+ ( createChromiumUser "gm" [ "audio" ] [ pkgs.chromium ] )
( createChromiumUser "flash" [ "audio" ] [ pkgs.flash ] )
];
diff --git a/lass/2configs/retiolum.nix b/lass/2configs/retiolum.nix
index f8a63706..1646cdea 100644
--- a/lass/2configs/retiolum.nix
+++ b/lass/2configs/retiolum.nix
@@ -16,8 +16,6 @@
enable = true;
connectTo = [
"prism"
- "cloudkrebs"
- "echelon"
"pigstarter"
"gum"
"flap"
diff --git a/lass/2configs/weechat.nix b/lass/2configs/weechat.nix
index 6a257f0b..98f5df42 100644
--- a/lass/2configs/weechat.nix
+++ b/lass/2configs/weechat.nix
@@ -1,14 +1,17 @@
{ config, lib, pkgs, ... }:
-{
- krebs.per-user.chat.packages = [
- pkgs.weechat
- pkgs.tmux
+let
+ inherit (config.krebs.lib) genid;
+in {
+ krebs.per-user.chat.packages = with pkgs; [
+ mosh
+ tmux
+ weechat
];
users.extraUsers.chat = {
home = "/home/chat";
- uid = lib.genid "chat";
+ uid = genid "chat";
useDefaultShell = true;
createHome = true;
openssh.authorizedKeys.keys = [
diff --git a/lass/3modules/newsbot-js.nix b/lass/3modules/newsbot-js.nix
index 5e340b26..0772971d 100644
--- a/lass/3modules/newsbot-js.nix
+++ b/lass/3modules/newsbot-js.nix
@@ -4,6 +4,8 @@ with builtins;
with lib;
let
+ inherit (config.krebs.lib) genid;
+
cfg = config.lass.newsbot-js;
out = {
diff --git a/makefu/1systems/omo.nix b/makefu/1systems/omo.nix
index 6cff35e9..ca0bfd2b 100644
--- a/makefu/1systems/omo.nix
+++ b/makefu/1systems/omo.nix
@@ -40,7 +40,6 @@ in {
networking.firewall.allowedTCPPorts = [ 80 655 8080 ];
# services.openssh.allowSFTP = false;
- krebs.build.source.nixpkgs.rev = "d0e3cca04edd5d1b3d61f188b4a5f61f35cdf1ce";
# copy config from <secrets/sabnzbd.ini> to /var/lib/sabnzbd/
services.sabnzbd.enable = true;
diff --git a/makefu/2configs/git/brain-retiolum.nix b/makefu/2configs/git/brain-retiolum.nix
index 58fd250e..80e4c87c 100644
--- a/makefu/2configs/git/brain-retiolum.nix
+++ b/makefu/2configs/git/brain-retiolum.nix
@@ -14,6 +14,7 @@ let
priv-repos = mapAttrs make-priv-repo {
autosync = { };
+ pass = { };
};
# TODO move users to separate module
diff --git a/makefu/2configs/git/cgit-retiolum.nix b/makefu/2configs/git/cgit-retiolum.nix
index 15700e10..0b69dbca 100644
--- a/makefu/2configs/git/cgit-retiolum.nix
+++ b/makefu/2configs/git/cgit-retiolum.nix
@@ -15,7 +15,7 @@ let
tinc_graphs = {
desc = "Tinc Advanced Graph Generation";
};
- cac = { };
+ cac-api = { };
init-stockholm = {
desc = "Init stuff for stockholm";
};
diff --git a/makefu/2configs/laptop-utils.nix b/makefu/2configs/laptop-utils.nix
new file mode 100644
index 00000000..b5ba2ec3
--- /dev/null
+++ b/makefu/2configs/laptop-utils.nix
@@ -0,0 +1,62 @@
+{ pkgs, ... }:
+
+# tools i use when actually working with the host.
+# package version will now be maintained by nix-rebuild
+#
+# essentially `nix-env -q` of the main user
+# TODO: split gui and non-gui
+{
+ environment.systemPackages = with pkgs; [
+ # core
+ at_spi2_core
+ acpi
+ bc
+ exif
+ file
+ ntfs3g
+ pv
+ proot
+ sshpass
+ unzip
+ unrar
+ usbutils
+ zip
+
+ # dev
+ python35Packages.virtualenv
+
+
+ # gui
+ clipit
+ feh
+ keepassx
+ pcmanfm
+ skype
+ tightvnc
+ gnome3.dconf
+ vlc
+ virtmanager
+ wireshark
+ xdotool
+
+ # browser
+ firefox
+ chromium
+
+ # sectools
+ aria2
+ binwalk
+ dnsmasq
+ iodine
+ mtr
+ nmap
+
+
+ # stuff
+ cac-cli
+ cac-panel
+ krebspaste
+ ledger
+ password-store
+ ];
+}
diff --git a/makefu/2configs/mail-client.nix b/makefu/2configs/mail-client.nix
index 913cbf25..03692407 100644
--- a/makefu/2configs/mail-client.nix
+++ b/makefu/2configs/mail-client.nix
@@ -3,6 +3,7 @@
with config.krebs.lib;
{
environment.systemPackages = with pkgs; [
+ abook
msmtp
mutt-kz
notmuch
@@ -10,5 +11,4 @@ with config.krebs.lib;
imapfilter
gnupg
];
-
}
diff --git a/makefu/2configs/main-laptop.nix b/makefu/2configs/main-laptop.nix
index 452cdfb2..3cc91b63 100644
--- a/makefu/2configs/main-laptop.nix
+++ b/makefu/2configs/main-laptop.nix
@@ -11,21 +11,11 @@ with config.krebs.lib;
./base-gui.nix
./fetchWallpaper.nix
./zsh-user.nix
+ ./laptop-utils.nix
];
users.users.${config.krebs.build.user.name}.extraGroups = [ "dialout" ];
- environment.systemPackages = with pkgs;[
- vlc
- firefox
- chromium
- keepassx
- ntfs3g
- at_spi2_core
- gnome3.dconf
- virtmanager
- krebspaste
- ];
services.redshift = {
enable = true;
diff --git a/makefu/5pkgs/default.nix b/makefu/5pkgs/default.nix
index 33e280f0..8caab433 100644
--- a/makefu/5pkgs/default.nix
+++ b/makefu/5pkgs/default.nix
@@ -9,7 +9,8 @@ in
alsa-hdspconf = callPackage ./alsa-tools { alsaToolTarget="hdspconf";};
alsa-hdsploader = callPackage ./alsa-tools { alsaToolTarget="hdsploader";};
awesomecfg = callPackage ./awesomecfg {};
- tw-upload-plugin = callPackage ./tw-upload-plugin {};
+ nodemcu-uploader = callPackage ./nodemcu-uploader {};
mycube-flask = callPackage ./mycube-flask {};
+ tw-upload-plugin = callPackage ./tw-upload-plugin {};
};
}
diff --git a/makefu/5pkgs/nodemcu-uploader/default.nix b/makefu/5pkgs/nodemcu-uploader/default.nix
new file mode 100644
index 00000000..64476be6
--- /dev/null
+++ b/makefu/5pkgs/nodemcu-uploader/default.nix
@@ -0,0 +1,22 @@
+{ lib, pkgs, pythonPackages, fetchurl, ... }:
+
+with pythonPackages; buildPythonPackage rec {
+ name = "nodemcu-uploader-${version}";
+ version = "0.2.2";
+ disabled = isPy3k || isPyPy;
+ propagatedBuildInputs = [
+ pyserial
+ ];
+ src = fetchurl {
+ url = "https://pypi.python.org/packages/source/n/nodemcu-uploader/nodemcu-uploader-${version}.tar.gz";
+ sha256 = "090giz84y9y3idgifp0yh80qqyv2czv6h3y55wyrlgf7qfbwbrvn";
+ };
+ # ImportError: No module named tests
+ # not sure what to do here
+ doCheck = false;
+ meta = {
+ homepage = https://github.com/kmpm/nodemcu-uploader;
+ description = "tool for uploading files to NodeMCU filesystem";
+ license = lib.licenses.mit;
+ };
+}