citadel

My dotfiles, scripts and nix configs
git clone git://jb55.com/citadel
Log | Files | Refs | README | LICENSE

commit 0324e430e5a018270f852af3f89c3bc123b5fc88
parent 298580e67316ad123d27230340a62f841a8a10ad
Author: William Casarin <jb55@jb55.com>
Date:   Tue,  1 Feb 2022 08:55:17 -0800

update nix config

Diffstat:
Mnix-config/environment/default.nix | 15++++++++++-----
Mnix-config/environment/desktop/default.nix | 7++++---
Mnix-config/hardware/desktop/default.nix | 2+-
Mnix-config/machines/charon/default.nix | 1-
Mnix-config/machines/quiver/default.nix | 11+++++++++--
Mnix-config/machines/quiver/networking/default.nix | 13+++++++++++++
Mnix-config/misc/imap-notifier/default.nix | 4++--
Mnix-config/nixpkgs/config.nix | 9+++++++++
Mnix-config/services/desktop/default.nix | 2+-
9 files changed, 49 insertions(+), 15 deletions(-)

diff --git a/nix-config/environment/default.nix b/nix-config/environment/default.nix @@ -13,7 +13,6 @@ let jb55pkgs = import <jb55pkgs> { inherit pkgs; }; btcs csv-delim csv-scripts - datefmt extname mandown ratio @@ -23,9 +22,6 @@ let jb55pkgs = import <jb55pkgs> { inherit pkgs; }; define nixpkgs-ml-tools ]; - myHaskellPackages = with pkgs.haskellPackages; [ - #skeletons - ]; minimal-pkgs = with pkgs; [ git-tools @@ -33,7 +29,16 @@ let jb55pkgs = import <jb55pkgs> { inherit pkgs; }; ripgrep ]; - mypkgs = with pkgs; myHaskellPackages ++ myPackages ++ [ + mypkgs = with pkgs; myPackages ++ [ + yq + tut + + python3Packages.num2words + python3Packages.howdoi + tree + datefmt + nncp + asciinema aspell aspellDicts.en aspellDicts.en-computers diff --git a/nix-config/environment/desktop/default.nix b/nix-config/environment/desktop/default.nix @@ -34,6 +34,7 @@ let gtk2rc = pkgs.writeText "gtk2rc" '' }; mypkgs = (with pkgs; [ + obs-studio aerc bitcoin clipmenu @@ -44,10 +45,10 @@ let gtk2rc = pkgs.writeText "gtk2rc" '' dunst dynamic-colors feh - getmail # for getmail-gmail-xoauth-tokens + getmail6 # for getmail-gmail-xoauth-tokens gnome3.gnome-calculator gtk-engine-murrine - hwi + #hwi khal lagrange lastpass-cli @@ -77,7 +78,7 @@ let gtk2rc = pkgs.writeText "gtk2rc" '' userConfig vdirsyncer w3m - wine + #wine wmctrl xautolock xbindkeys diff --git a/nix-config/hardware/desktop/default.nix b/nix-config/hardware/desktop/default.nix @@ -84,7 +84,7 @@ in EndSection ''; - services.printing.drivers = [ pkgs.samsung-unified-linux-driver_4_01_17 ]; + services.printing.drivers = [ pkgs.cups-brother-hll2370dw ]; boot.blacklistedKernelModules = ["dvb_usb_rtl28xxu"]; fileSystems."/media/kindle" = diff --git a/nix-config/machines/charon/default.nix b/nix-config/machines/charon/default.nix @@ -262,7 +262,6 @@ in authentication = '' # type db user address method local all all trust - host all all 172.24.0.0/16 trust host all all 127.0.0.1/16 trust ''; #extraConfig = '' diff --git a/nix-config/machines/quiver/default.nix b/nix-config/machines/quiver/default.nix @@ -24,6 +24,7 @@ extra: services.teamviewer.enable = false; services.synergy.server.enable = true; + services.synergy.server.tls.enable = false; services.synergy.server.screenName = "quiver"; services.synergy.server.autoStart = true; services.synergy.server.configFile = pkgs.writeText "barrier-cfg" '' @@ -150,7 +151,12 @@ extra: wantedBy = [ "default.target" ]; after = [ "default.target" ]; - path = with pkgs; [ gnused acpi ]; + path = with pkgs; [ gnused acpi libnotify ]; + + environment = { + DISPLAY=":0"; + DBUS_SESSION_BUS_ADDRESS="unix:path=/run/user/1000/bus"; + }; serviceConfig.ExecStart = extra.util.writeBash "battery-power" '' set -e @@ -170,6 +176,7 @@ extra: if ! acpi -b | grep Charging && [ $percent -lt $limit ] && [ "$state" != "heartbeat" ] then printf "battery %d%% < %d%%, setting heartbeat trigger\n" "$percent" "$limit" >&2 + notify-send "battery low: %$percent" echo heartbeat > "$LED"/trigger echo heartbeat > "$LED2"/trigger state="heartbeat" @@ -219,7 +226,7 @@ extra: services.postgresql = { dataDir = "/var/db/postgresql/10/"; - enable = false; + enable = true; package = pkgs.postgresql_10; # extraPlugins = with pkgs; [ pgmp ]; authentication = pkgs.lib.mkForce '' diff --git a/nix-config/machines/quiver/networking/default.nix b/nix-config/machines/quiver/networking/default.nix @@ -40,6 +40,19 @@ in networking.wireguard.interfaces = { # "wg0" is the network interface name. You can name the interface arbitrarily. + rcx0 = { + ips = [ "10.200.0.5/32" ]; + + privateKeyFile = "/home/jb55/.wg/private"; + + peers = [ + { publicKey = "wC+mEE9/PJDuIfr7DFZWnM8HbQz5fSOFHmmzQRxULzM="; + allowedIPs = [ "10.200.0.1/32" ]; + endpoint = "159.89.143.225:53"; + } + ]; + }; + wg0 = { # Determines the IP address and subnet of the client's end of the tunnel interface. ips = [ "10.100.0.2/28" ]; diff --git a/nix-config/misc/imap-notifier/default.nix b/nix-config/misc/imap-notifier/default.nix @@ -1,9 +1,9 @@ extra: { config, lib, pkgs, ... }: let imap-notify = (import <jb55pkgs> {}).imap-notify; - penv = pkgs.python2.withPackages (ps: with ps; [ dbus-python pygobject2 ]); + penv = pkgs.python3.withPackages (ps: with ps; [ dbus-python pygobject3 ]); awake-from-sleep-fetcher = pkgs.writeScript "awake-from-sleep-fetcher" '' - #!${penv}/bin/python2 -u + #!${penv}/bin/python3 -u import dbus import datetime diff --git a/nix-config/nixpkgs/config.nix b/nix-config/nixpkgs/config.nix @@ -34,6 +34,15 @@ in { inherit pkgs; }; + less = pkgs.lib.overrideDerivation super.less (attrs: { + patches = [ + (super.fetchurl { + url = "https://jb55.com/s/0001-Fix-regression-where-lastmark-isn-t-saved-250.patch"; + sha256 = "0171f3c60406232fdd24a3c7a59fa7dd92b673b612998a545459d704ba922ca2"; + }) + ]; + }); + msmtp = pkgs.lib.overrideDerivation super.msmtp (attrs: { patches = [ (super.fetchurl { diff --git a/nix-config/services/desktop/default.nix b/nix-config/services/desktop/default.nix @@ -26,7 +26,7 @@ in services.pcscd.enable = true; services.gnome3.gnome-keyring.enable = if extra.is-minimal then false else true; - services.trezord.enable = false; + services.trezord.enable = true; services.avahi.enable = true; services.avahi.publish.enable = true;