From 6ed502d51c98b84fbdf147d2bfac81d1ce7a9670 Mon Sep 17 00:00:00 2001 From: fruchti Date: Mon, 27 Nov 2023 11:02:18 +0100 Subject: [PATCH 01/61] Gitea: Disable Jupyter notebook rendering --- hosts/gitea.nix | 43 ++++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 21 deletions(-) diff --git a/hosts/gitea.nix b/hosts/gitea.nix index 9de795d..bb89abd 100644 --- a/hosts/gitea.nix +++ b/hosts/gitea.nix @@ -22,12 +22,13 @@ in contentDir = "/data/git/data/lfs"; }; settings = let + python = pkgs.python311; docutils = - pkgs.python310.withPackages (ps: with ps; [ + python.withPackages (ps: with ps; [ docutils # Provides rendering of ReStructured Text files pygments # Provides syntax highlighting ]); - nbconvert = pkgs.python310.withPackages (ps: with ps; [ + nbconvert = python.withPackages (ps: with ps; [ jupyter ipykernel nbconvert @@ -78,25 +79,25 @@ in RENDER_COMMAND = "${docutils}/bin/rst2html.py"; IS_INPUT_FILE = false; }; - "markup.jupyter" = { - ENABLED = true; - FILE_EXTENSIONS = ".ipynb"; - # RENDER_COMMAND = "\"${nbconvert}/bin/jupyter nbconvert --stdout --to html --template basic \""; - RENDER_COMMAND = "\"${cached_jupyter_preview} \""; - IS_INPUT_FILE = true; - # RENDER_CONTENT_MODE = "iframe"; - }; - "markup.sanitizer.jupyter.div" = { ELEMENT = "div"; ALLOW_ATTR = "class"; REGEXP = ""; }; - "markup.sanitizer.jupyter.span" = { ELEMENT = "span"; ALLOW_ATTR = "class"; REGEXP = ""; }; - "markup.sanitizer.jupyter.img" = { ELEMENT = "img"; ALLOW_ATTR = "class"; REGEXP = ""; ALLOW_DATA_URI_IMAGES = "true"; }; - "markup.sanitizer.jupyter.svg.width" = { ELEMENT = "svg"; ALLOW_ATTR = "width"; REGEXP = ""; }; - "markup.sanitizer.jupyter.svg.height" = { ELEMENT = "svg"; ALLOW_ATTR = "height"; REGEXP = ""; }; - "markup.sanitizer.jupyter.svg.viewbox" = { ELEMENT = "svg"; ALLOW_ATTR = "viewbox"; REGEXP = ""; }; - "markup.sanitizer.jupyter.svg.use" = { ELEMENT = "use"; ALLOW_ATTR = "transform"; REGEXP = ""; }; - "markup.sanitizer.jupyter.svg.g" = { ELEMENT = "g"; ALLOW_ATTR = "class"; REGEXP = ""; }; - "markup.sanitizer.jupyter.svg.path.style" = { ELEMENT = "path"; ALLOW_ATTR = "style"; REGEXP = ""; }; - "markup.sanitizer.jupyter.svg.path.d" = { ELEMENT = "path"; ALLOW_ATTR = "d"; REGEXP = ""; }; - "markup.sanitizer.jupyter.svg.path.transform" = { ELEMENT = "path"; ALLOW_ATTR = "transform"; REGEXP = ""; }; + # "markup.jupyter" = { + # ENABLED = true; + # FILE_EXTENSIONS = ".ipynb"; + # # RENDER_COMMAND = "\"${nbconvert}/bin/jupyter nbconvert --stdout --to html --template basic \""; + # RENDER_COMMAND = "\"${cached_jupyter_preview} \""; + # IS_INPUT_FILE = true; + # # RENDER_CONTENT_MODE = "iframe"; + # }; + # "markup.sanitizer.jupyter.div" = { ELEMENT = "div"; ALLOW_ATTR = "class"; REGEXP = ""; }; + # "markup.sanitizer.jupyter.span" = { ELEMENT = "span"; ALLOW_ATTR = "class"; REGEXP = ""; }; + # "markup.sanitizer.jupyter.img" = { ELEMENT = "img"; ALLOW_ATTR = "class"; REGEXP = ""; ALLOW_DATA_URI_IMAGES = "true"; }; + # "markup.sanitizer.jupyter.svg.width" = { ELEMENT = "svg"; ALLOW_ATTR = "width"; REGEXP = ""; }; + # "markup.sanitizer.jupyter.svg.height" = { ELEMENT = "svg"; ALLOW_ATTR = "height"; REGEXP = ""; }; + # "markup.sanitizer.jupyter.svg.viewbox" = { ELEMENT = "svg"; ALLOW_ATTR = "viewbox"; REGEXP = ""; }; + # "markup.sanitizer.jupyter.svg.use" = { ELEMENT = "use"; ALLOW_ATTR = "transform"; REGEXP = ""; }; + # "markup.sanitizer.jupyter.svg.g" = { ELEMENT = "g"; ALLOW_ATTR = "class"; REGEXP = ""; }; + # "markup.sanitizer.jupyter.svg.path.style" = { ELEMENT = "path"; ALLOW_ATTR = "style"; REGEXP = ""; }; + # "markup.sanitizer.jupyter.svg.path.d" = { ELEMENT = "path"; ALLOW_ATTR = "d"; REGEXP = ""; }; + # "markup.sanitizer.jupyter.svg.path.transform" = { ELEMENT = "path"; ALLOW_ATTR = "transform"; REGEXP = ""; }; }; }; From a5d18374bf46137cc4f4b25a467c294103811d5a Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 2 Dec 2023 20:29:47 +0100 Subject: [PATCH 02/61] Emitter: Change configuration for new home --- hosts/Emitter.nix | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/hosts/Emitter.nix b/hosts/Emitter.nix index 5400a99..7efdace 100644 --- a/hosts/Emitter.nix +++ b/hosts/Emitter.nix @@ -6,7 +6,7 @@ ]; boot.loader.grub.enable = true; - boot.loader.grub.device = "/dev/vda"; + boot.loader.grub.device = "/dev/sda"; networking.hostName = "Emitter"; @@ -14,12 +14,12 @@ networking.useDHCP = false; networking = { defaultGateway = { - address = "2.59.133.1"; - interface = "ens3"; + address = "176.96.139.1"; + interface = "ens18"; }; defaultGateway6 = { - address = "2a0d:5940:7::1"; - interface = "ens3"; + address = "2a0d:5940:80:4e::1"; + interface = "ens18"; }; nameservers = [ "9.9.9.10" @@ -27,38 +27,38 @@ "2606:4700:4700::1111" "2001:4860:4860::8888" ]; - interfaces.ens3 = { + interfaces.ens18 = { ipv4 = { addresses = [ { - address = "2.59.133.12"; + address = "176.96.139.54"; prefixLength = 24; } ]; routes = [ { - address = "2.59.133.0"; + address = "176.96.139.0"; prefixLength = 24; - via = "2.59.133.1"; + via = "176.96.139.1"; } ]; }; ipv6 = { addresses = [ { - address = "2a0d:5940:7:16f:216:3cff:fe63:9a54"; + address = "2a0d:5940:80:4e::2"; prefixLength = 64; } { - address = "fe80::216:3cff:fe63:9a54"; + address = "fe80::4874:40ff:fe38:7a45"; prefixLength = 64; } ]; routes = [ { - address = "2a0d:5940:7:16f:216:3cff:fe63:9a54"; + address = "2a0d:5940:80:4e::2"; prefixLength = 64; - via = "2a0d:5940:7::1"; + via = "2a0d:5940:80:4e::1"; } ]; }; From 2494def822466ddb7743bf23e80e00efc178422f Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 2 Dec 2023 20:30:31 +0100 Subject: [PATCH 03/61] Add magic-wormhole to default installation packages --- base/packages.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/base/packages.nix b/base/packages.nix index a2645ed..ab913fd 100644 --- a/base/packages.nix +++ b/base/packages.nix @@ -5,6 +5,7 @@ tmux zellij wget rsync + magic-wormhole git gnupg file From 7d14f4a8df1964bddaa70cea65506828ad721a48 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 2 Dec 2023 20:34:17 +0100 Subject: [PATCH 04/61] Disco: Add swap file, earlyoom --- hosts/Disco.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index 09c5437..8f28c01 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -172,6 +172,16 @@ LidSwitchIgnoreInhibited = no ''; + services.earlyoom = { + enable = true; + enableNotifications = true; + }; + + swapDevices = [{ + device = "/swapfile"; + size = 16 * 1024; + }]; + # This value determines the NixOS release from which the default # settings for stateful data, like file locations and database versions # on your system were taken. It‘s perfectly fine and recommended to leave From d6f2c33a0948feb0b2218b97471df1cd5553c465 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 2 Dec 2023 20:34:42 +0100 Subject: [PATCH 05/61] X270: Try to fix nub wakeup issue --- hosts/x270.nix | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/hosts/x270.nix b/hosts/x270.nix index 70b3ef0..30f75e8 100644 --- a/hosts/x270.nix +++ b/hosts/x270.nix @@ -6,6 +6,17 @@ speed = 170; }; + # Ensure that trackpoint mouse buttons work after suspend without having + # to touch the trackpoint first + powerManagement = { + powerDownCommands = '' + modprobe -r psmouse + ''; + resumeCommands = '' + modprobe psmouse + ''; + }; + services.xserver.videoDrivers = [ "modesetting" ]; boot.initrd.kernelModules = [ "i915" ]; From f678ad57f87d754020323712062851c0271f7eb1 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 2 Dec 2023 21:35:50 +0100 Subject: [PATCH 06/61] Rupert: Add working video decoding HW acceleration --- hosts/Rupert.nix | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index f1e8896..df4868b 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -21,6 +21,24 @@ in boot.loader.efi.canTouchEfiVariables = true; boot.kernelParams = [ "acpi=force" "reboot=bios" ]; + boot.initrd.kernelModules = [ "i915" ]; + nixpkgs.config.packageOverrides = pkgs: { + vaapiIntel = pkgs.vaapiIntel.override { enableHybridCodec = true; }; + }; + hardware.opengl = { + enable = true; + extraPackages = with pkgs; [ + (if (lib.versionOlder (lib.versions.majorMinor lib.version) "23.11") then vaapiIntel else intel-vaapi-driver) + libvdpau-va-gl + vaapiVdpau + # intel-media-driver + ]; + }; + environment.variables = { + VDPAU_DRIVER = "va_gl"; + }; + hardware.cpu.intel.updateMicrocode = true; + networking.hostName = "Rupert"; users.users = { From 131c18230a1febb74c8a0d004eb79816a14cafdf Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 2 Dec 2023 21:36:19 +0100 Subject: [PATCH 07/61] Rupert: Add changes for 23.11 --- base/packages.nix | 2 +- hosts/Rupert.nix | 1 + hosts/hedgedoc.nix | 1 - hosts/nextcloud.nix | 19 ++++++++----------- 4 files changed, 10 insertions(+), 13 deletions(-) diff --git a/base/packages.nix b/base/packages.nix index ab913fd..b0d0b0a 100644 --- a/base/packages.nix +++ b/base/packages.nix @@ -38,7 +38,7 @@ xsel ]; - fonts.fonts = with pkgs; [ + fonts.packages = with pkgs; [ vollkorn alegreya alegreya-sans b612 diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index df4868b..aad751c 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -74,6 +74,7 @@ in services.flatpak.enable = true; xdg.portal.extraPortals = [ pkgs.xdg-desktop-portal-gtk ]; xdg.portal.enable = true; + xdg.portal.config.common.default = "*"; hardware.bluetooth = { enable = true; diff --git a/hosts/hedgedoc.nix b/hosts/hedgedoc.nix index 336db42..b237e92 100644 --- a/hosts/hedgedoc.nix +++ b/hosts/hedgedoc.nix @@ -5,7 +5,6 @@ in { services.hedgedoc = { enable = true; - workDir = "/data/hedgedoc"; environmentFile = "/secrets/hedgedoc.env"; settings = { port = 7000; diff --git a/hosts/nextcloud.nix b/hosts/nextcloud.nix index fd907d5..c5ac748 100644 --- a/hosts/nextcloud.nix +++ b/hosts/nextcloud.nix @@ -6,7 +6,7 @@ in services.nextcloud = { enable = true; https = true; - package = pkgs.nextcloud26; + package = pkgs.nextcloud27; hostName = hostName; datadir = "/data/nextcloud"; config = { @@ -19,7 +19,6 @@ in ]; }; caching.redis = true; - enableBrokenCiphersForSSE = false; }; services.postgresql = { @@ -27,16 +26,14 @@ in ensureUsers = [ { name = "nextcloud"; - ensurePermissions = { - "DATABASE nextcloud" = "ALL PRIVILEGES"; - }; - } - { - name = "superuser"; - ensurePermissions = { - "ALL TABLES IN SCHEMA public" = "ALL PRIVILEGES"; - }; + ensureDBOwnership = true; } + # { + # name = "superuser"; + # ensurePermissions = { + # "ALL TABLES IN SCHEMA public" = "ALL PRIVILEGES"; + # }; + # } ]; ensureDatabases = [ "nextcloud" ]; }; From c0baac04884acde1489b61a37005503ff322bdae Mon Sep 17 00:00:00 2001 From: fruchti Date: Sun, 3 Dec 2023 11:44:46 +0100 Subject: [PATCH 08/61] Emitter: Switch to Forgejo --- hosts/Emitter.nix | 2 +- .../public/css/fonts.css | 0 .../public/css/jupyter.css | 0 ...v21-latin-ext_latin_greek_cyrillic-700.eot | Bin ...v21-latin-ext_latin_greek_cyrillic-700.svg | 0 ...v21-latin-ext_latin_greek_cyrillic-700.ttf | Bin ...21-latin-ext_latin_greek_cyrillic-700.woff | Bin ...1-latin-ext_latin_greek_cyrillic-700.woff2 | Bin ...latin-ext_latin_greek_cyrillic-regular.eot | Bin ...latin-ext_latin_greek_cyrillic-regular.svg | 0 ...latin-ext_latin_greek_cyrillic-regular.ttf | Bin ...atin-ext_latin_greek_cyrillic-regular.woff | Bin ...tin-ext_latin_greek_cyrillic-regular.woff2 | Bin .../hammersmith-one-v17-latin-regular.eot | Bin .../hammersmith-one-v17-latin-regular.svg | 0 .../hammersmith-one-v17-latin-regular.ttf | Bin .../hammersmith-one-v17-latin-regular.woff | Bin .../hammersmith-one-v17-latin-regular.woff2 | Bin ...v21-latin-ext_latin_greek_cyrillic-700.eot | Bin ...v21-latin-ext_latin_greek_cyrillic-700.svg | 0 ...v21-latin-ext_latin_greek_cyrillic-700.ttf | Bin ...21-latin-ext_latin_greek_cyrillic-700.woff | Bin ...1-latin-ext_latin_greek_cyrillic-700.woff2 | Bin ...tin-ext_latin_greek_cyrillic-700italic.eot | Bin ...tin-ext_latin_greek_cyrillic-700italic.svg | 0 ...tin-ext_latin_greek_cyrillic-700italic.ttf | Bin ...in-ext_latin_greek_cyrillic-700italic.woff | Bin ...n-ext_latin_greek_cyrillic-700italic.woff2 | Bin ...-latin-ext_latin_greek_cyrillic-italic.eot | Bin ...-latin-ext_latin_greek_cyrillic-italic.svg | 0 ...-latin-ext_latin_greek_cyrillic-italic.ttf | Bin ...latin-ext_latin_greek_cyrillic-italic.woff | Bin ...atin-ext_latin_greek_cyrillic-italic.woff2 | Bin ...latin-ext_latin_greek_cyrillic-regular.eot | Bin ...latin-ext_latin_greek_cyrillic-regular.svg | 0 ...latin-ext_latin_greek_cyrillic-regular.ttf | Bin ...atin-ext_latin_greek_cyrillic-regular.woff | Bin ...tin-ext_latin_greek_cyrillic-regular.woff2 | Bin .../public/img/apple-touch-icon.png | Bin .../public/img/avatar_default.png | Bin .../public/img/favicon.png | Bin .../public/img/favicon.svg | 0 .../public/img/logo.png | Bin .../public/img/logo.svg | 0 .../templates/custom/extra_links_footer.tmpl | 0 .../templates/custom/header.tmpl | 0 .../templates/home.tmpl | 0 hosts/{gitea.nix => forgejo.nix} | 34 +++++++++--------- 48 files changed, 19 insertions(+), 17 deletions(-) rename hosts/{gitea-custom => forgejo-custom}/public/css/fonts.css (100%) rename hosts/{gitea-custom => forgejo-custom}/public/css/jupyter.css (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/hammersmith-one-v17-latin-regular.eot (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/hammersmith-one-v17-latin-regular.svg (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/hammersmith-one-v17-latin-regular.ttf (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/hammersmith-one-v17-latin-regular.woff (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/hammersmith-one-v17-latin-regular.woff2 (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff (100%) rename hosts/{gitea-custom => forgejo-custom}/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 (100%) rename hosts/{gitea-custom => forgejo-custom}/public/img/apple-touch-icon.png (100%) rename hosts/{gitea-custom => forgejo-custom}/public/img/avatar_default.png (100%) rename hosts/{gitea-custom => forgejo-custom}/public/img/favicon.png (100%) rename hosts/{gitea-custom => forgejo-custom}/public/img/favicon.svg (100%) rename hosts/{gitea-custom => forgejo-custom}/public/img/logo.png (100%) rename hosts/{gitea-custom => forgejo-custom}/public/img/logo.svg (100%) rename hosts/{gitea-custom => forgejo-custom}/templates/custom/extra_links_footer.tmpl (100%) rename hosts/{gitea-custom => forgejo-custom}/templates/custom/header.tmpl (100%) rename hosts/{gitea-custom => forgejo-custom}/templates/home.tmpl (100%) rename hosts/{gitea.nix => forgejo.nix} (82%) diff --git a/hosts/Emitter.nix b/hosts/Emitter.nix index 7efdace..5aa3ac7 100644 --- a/hosts/Emitter.nix +++ b/hosts/Emitter.nix @@ -1,7 +1,7 @@ { config, pkgs, ... }: { imports = [ - ./gitea.nix + ./forgejo.nix ./tls_sni.nix ]; diff --git a/hosts/gitea-custom/public/css/fonts.css b/hosts/forgejo-custom/public/css/fonts.css similarity index 100% rename from hosts/gitea-custom/public/css/fonts.css rename to hosts/forgejo-custom/public/css/fonts.css diff --git a/hosts/gitea-custom/public/css/jupyter.css b/hosts/forgejo-custom/public/css/jupyter.css similarity index 100% rename from hosts/gitea-custom/public/css/jupyter.css rename to hosts/forgejo-custom/public/css/jupyter.css diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff diff --git a/hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 b/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 similarity index 100% rename from hosts/gitea-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 rename to hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 diff --git a/hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.eot b/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.eot similarity index 100% rename from hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.eot rename to hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.eot diff --git a/hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.svg b/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.svg similarity index 100% rename from hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.svg rename to hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.svg diff --git a/hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.ttf b/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.ttf similarity index 100% rename from hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.ttf rename to hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.ttf diff --git a/hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.woff b/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.woff similarity index 100% rename from hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.woff rename to hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.woff diff --git a/hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.woff2 b/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.woff2 similarity index 100% rename from hosts/gitea-custom/public/fonts/hammersmith-one-v17-latin-regular.woff2 rename to hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.woff2 diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff diff --git a/hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 b/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 similarity index 100% rename from hosts/gitea-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 rename to hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 diff --git a/hosts/gitea-custom/public/img/apple-touch-icon.png b/hosts/forgejo-custom/public/img/apple-touch-icon.png similarity index 100% rename from hosts/gitea-custom/public/img/apple-touch-icon.png rename to hosts/forgejo-custom/public/img/apple-touch-icon.png diff --git a/hosts/gitea-custom/public/img/avatar_default.png b/hosts/forgejo-custom/public/img/avatar_default.png similarity index 100% rename from hosts/gitea-custom/public/img/avatar_default.png rename to hosts/forgejo-custom/public/img/avatar_default.png diff --git a/hosts/gitea-custom/public/img/favicon.png b/hosts/forgejo-custom/public/img/favicon.png similarity index 100% rename from hosts/gitea-custom/public/img/favicon.png rename to hosts/forgejo-custom/public/img/favicon.png diff --git a/hosts/gitea-custom/public/img/favicon.svg b/hosts/forgejo-custom/public/img/favicon.svg similarity index 100% rename from hosts/gitea-custom/public/img/favicon.svg rename to hosts/forgejo-custom/public/img/favicon.svg diff --git a/hosts/gitea-custom/public/img/logo.png b/hosts/forgejo-custom/public/img/logo.png similarity index 100% rename from hosts/gitea-custom/public/img/logo.png rename to hosts/forgejo-custom/public/img/logo.png diff --git a/hosts/gitea-custom/public/img/logo.svg b/hosts/forgejo-custom/public/img/logo.svg similarity index 100% rename from hosts/gitea-custom/public/img/logo.svg rename to hosts/forgejo-custom/public/img/logo.svg diff --git a/hosts/gitea-custom/templates/custom/extra_links_footer.tmpl b/hosts/forgejo-custom/templates/custom/extra_links_footer.tmpl similarity index 100% rename from hosts/gitea-custom/templates/custom/extra_links_footer.tmpl rename to hosts/forgejo-custom/templates/custom/extra_links_footer.tmpl diff --git a/hosts/gitea-custom/templates/custom/header.tmpl b/hosts/forgejo-custom/templates/custom/header.tmpl similarity index 100% rename from hosts/gitea-custom/templates/custom/header.tmpl rename to hosts/forgejo-custom/templates/custom/header.tmpl diff --git a/hosts/gitea-custom/templates/home.tmpl b/hosts/forgejo-custom/templates/home.tmpl similarity index 100% rename from hosts/gitea-custom/templates/home.tmpl rename to hosts/forgejo-custom/templates/home.tmpl diff --git a/hosts/gitea.nix b/hosts/forgejo.nix similarity index 82% rename from hosts/gitea.nix rename to hosts/forgejo.nix index 9de795d..ce2ff36 100644 --- a/hosts/gitea.nix +++ b/hosts/forgejo.nix @@ -2,18 +2,17 @@ let domain = "git.25120.org"; - giteaCustom = pkgs.callPackage ../packages/directory.nix { - name = "gitea-custom"; - source = ./gitea-custom; + forgejoCustom = pkgs.callPackage ../packages/directory.nix { + name = "forgejo-custom"; + source = ./forgejo-custom; }; in { - services.gitea = { + services.forgejo = { enable = true; - appName = "${domain}"; database = { type = "postgres"; - passwordFile = "/secrets/gitea_db_password"; + passwordFile = "/secrets/forgejo_db_password"; createDatabase = false; }; repositoryRoot = "/data/git/repositories"; @@ -22,12 +21,13 @@ in contentDir = "/data/git/data/lfs"; }; settings = let + python = pkgs.python311; docutils = - pkgs.python310.withPackages (ps: with ps; [ + python.withPackages (ps: with ps; [ docutils # Provides rendering of ReStructured Text files pygments # Provides syntax highlighting ]); - nbconvert = pkgs.python310.withPackages (ps: with ps; [ + nbconvert = python.withPackages (ps: with ps; [ jupyter ipykernel nbconvert @@ -41,7 +41,7 @@ in input_file="$1" command="${nbconvert}/bin/jupyter nbconvert --stdout --to html --template basic" - cache_directory="${config.services.gitea.stateDir}/markup_cache/jupyter" + cache_directory="${config.services.forgejo.stateDir}/markup_cache/jupyter" max_cache_file_count="${toString max_cached_jupyter_notebooks}" cache_file="$cache_directory/$(md5sum "$input_file" | cut -d' ' -f1)" @@ -64,6 +64,7 @@ in ''; in { + DEFAULT.APP_NAME = "${domain}"; server = { SSH_PORT = lib.head config.services.openssh.ports; ROOT_URL = "https://${domain}/"; @@ -72,6 +73,7 @@ in }; service.DISABLE_REGISTRATION = true; session.COOKIE_SECURE = true; + UI.DEFAULT_THEME = "forgejo-auto"; "markup.restructuredtext" = { ENABLED = true; FILE_EXTENSIONS = ".rst"; @@ -103,11 +105,11 @@ in services.postgresql = { enable = true; authentication = '' - local gitea all ident map=gitea-users + local forgejo all ident map=forgejo-users ''; - # Map the gitea user to postgresql + # Map the forgejo user to postgresql identMap = '' - gitea-users gitea gitea + forgejo-users forgejo forgejo ''; }; @@ -124,14 +126,14 @@ in }; }; - # users.users.gitea.extraGroups = [ "keys" ]; - systemd.services.gitea = { + # users.users.forgejo.extraGroups = [ "keys" ]; + systemd.services.forgejo = { serviceConfig = { ReadOnlyPaths = [ "/secrets" ]; }; preStart = '' - cp -frT "${giteaCustom}/" "${config.services.gitea.stateDir}/custom/" - find "${config.services.gitea.stateDir}/custom/" -type d -exec chmod 0750 '{}' + -or -type f -exec chmod 0640 '{}' + + cp -frT "${forgejoCustom}/" "${config.services.forgejo.stateDir}/custom/" + find "${config.services.forgejo.stateDir}/custom/" -type d -exec chmod 0750 '{}' + -or -type f -exec chmod 0640 '{}' + ''; }; From 7a7eb0e9fbf3b8c8ac849075e970d870becf6a57 Mon Sep 17 00:00:00 2001 From: fruchti Date: Tue, 5 Dec 2023 20:36:45 +0100 Subject: [PATCH 09/61] WCH-LinkE udev rule: Also match USB-UART --- hosts/development.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/development.nix b/hosts/development.nix index c801216..7236f1a 100644 --- a/hosts/development.nix +++ b/hosts/development.nix @@ -31,7 +31,7 @@ SUBSYSTEM=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3748", MODE="0660", GROUP="plugdev" # WCH-LinkE - SUBSYSTEM=="usb", ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="8010", MODE="0660", GROUP="plugdev" + SUBSYSTEMS=="usb", ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="8010", MODE="0660", GROUP="plugdev" # Glasgow SUBSYSTEM=="usb", ATTRS{idVendor}=="20b7", ATTRS{idProduct}=="9db1", MODE="0660", GROUP="plugdev" From c44799033a816e06ae268244794fe065ea7a3b00 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:30:08 +0200 Subject: [PATCH 10/61] Remove joshuto for now --- base/packages.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/packages.nix b/base/packages.nix index b0d0b0a..41ae6de 100644 --- a/base/packages.nix +++ b/base/packages.nix @@ -14,7 +14,7 @@ htop ncdu killall - ranger nnn joshuto + ranger nnn # joshuto hexyl rink From b67bf68f0dd0d46a413ca869fbbf1775ca130d2c Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:31:11 +0200 Subject: [PATCH 11/61] Hedgedoc: Replace ensurePermissions --- hosts/hedgedoc.nix | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/hosts/hedgedoc.nix b/hosts/hedgedoc.nix index b237e92..8f57ff0 100644 --- a/hosts/hedgedoc.nix +++ b/hosts/hedgedoc.nix @@ -38,9 +38,7 @@ in ensureUsers = [ { name = "hedgedoc"; - ensurePermissions = { - "DATABASE hedgedoc" = "ALL PRIVILEGES"; - }; + ensureDBOwnership = true; } ]; ensureDatabases = [ "hedgedoc" ]; From 9195d6f6de4f02859492502eb44b268cb9b2b51f Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:32:05 +0200 Subject: [PATCH 12/61] Horizon EDA: Fix Intel GPU redraw issue --- overlays/default.nix | 1 + overlays/horizon-eda.nix | 13 +++++++++++++ overlays/horizon_software_draw_surface.patch | 10 ++++++++++ 3 files changed, 24 insertions(+) create mode 100644 overlays/horizon-eda.nix create mode 100644 overlays/horizon_software_draw_surface.patch diff --git a/overlays/default.nix b/overlays/default.nix index 7cd1fd2..eab7738 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -2,5 +2,6 @@ { imports = [ ./burp.nix + ./horizon-eda.nix ]; } diff --git a/overlays/horizon-eda.nix b/overlays/horizon-eda.nix new file mode 100644 index 0000000..3022fdf --- /dev/null +++ b/overlays/horizon-eda.nix @@ -0,0 +1,13 @@ +{ config, ... }: +{ + nixpkgs.overlays = [ + (self: super: { + horizon-eda = (super.horizon-eda.overrideAttrs (old: { + # Add an environment variable to fix redraw issues on Intel Graphics + patches = [ + ./horizon_software_draw_surface.patch + ]; + })); + }) + ]; +} diff --git a/overlays/horizon_software_draw_surface.patch b/overlays/horizon_software_draw_surface.patch new file mode 100644 index 0000000..c44c667 --- /dev/null +++ b/overlays/horizon_software_draw_surface.patch @@ -0,0 +1,10 @@ +diff --git a/org.horizon_eda.HorizonEDA.desktop b/org.horizon_eda.HorizonEDA.desktop +index 7551df54..d8df7800 100644 +--- a/org.horizon_eda.HorizonEDA.desktop ++++ b/org.horizon_eda.HorizonEDA.desktop +@@ -5,4 +5,4 @@ Categories=Development;Engineering;Electronics; + Type=Application + Terminal=false + Icon=org.horizon_eda.HorizonEDA +-Exec=horizon-eda %U ++Exec=env GDK_GL=software-draw-surface horizon-eda %U From 958117375a72a8f71ae202701218461de9868cee Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:33:05 +0200 Subject: [PATCH 13/61] =?UTF-8?q?Fix=20=E2=80=98sudo=20nixos-rebuild?= =?UTF-8?q?=E2=80=99=20asking=20for=20password?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- base/users.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/users.nix b/base/users.nix index 298c65c..e6f84cb 100644 --- a/base/users.nix +++ b/base/users.nix @@ -24,7 +24,7 @@ in groups = [ "wheel" ]; commands = [ { - command = "${pkgs.nixos-rebuild}/bin/nixos-rebuild *"; + command = "/run/current-system/sw/bin/nixos-rebuild"; options = [ "NOPASSWD" ]; } ]; From 2a4dce6e025b81db1f131e4dfeb86d76575f0edd Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:34:02 +0200 Subject: [PATCH 14/61] GNOME: Explicitly enable gnome-keyring --- hosts/gnome.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/gnome.nix b/hosts/gnome.nix index 41ab98f..08b1aca 100644 --- a/hosts/gnome.nix +++ b/hosts/gnome.nix @@ -11,6 +11,7 @@ autoLogin.user = "fruchti"; }; security.pam.services.gdm.enableGnomeKeyring = true; + services.gnome.gnome-keyring.enable = true; services.touchegg.enable = true; services.gnome.gnome-settings-daemon.enable = true; From d0d2f1f64e930a65f369dea5c36786e55fbd3e80 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:35:50 +0200 Subject: [PATCH 15/61] Emitter: Send e-mail only on repeated backup fails --- hosts/Emitter.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hosts/Emitter.nix b/hosts/Emitter.nix index 5aa3ac7..fac76c3 100644 --- a/hosts/Emitter.nix +++ b/hosts/Emitter.nix @@ -131,7 +131,11 @@ }; serviceConfig = { Restart = "on-failure"; + RestartSec = retryDelay; + # Skip transitions through failed state, i.e. don’t send a e-mail + # before the maximum number of retries is exhausted + RestartMode = "direct"; }; }; From 801a472e99a2f149bd72f146b9b1984a97feda1f Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:36:36 +0200 Subject: [PATCH 16/61] Status e-mail: Use only main process exit code Previously, the exit code of an ExitStartPre script might have wound up in the e-mail subject. --- options/status-email.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/options/status-email.nix b/options/status-email.nix index 4dfaa74..9477ab7 100644 --- a/options/status-email.nix +++ b/options/status-email.nix @@ -20,7 +20,7 @@ in to="${toAddress}" service="$1" full_status="$(systemctl status --full --lines 200 "$service")" - exit_code="$(echo "$full_status" | head -n5 | tail -1 | sed -e 's/.*status=\(.*\))$/\1/g')" + exit_code="$(echo "$full_status" | head -n5 | tail -1 | sed -e 's/.*ExecStart=.*status=\(.*\))$/\1/g')" # state="$(systemctl is-failed "$service")" fail_priority=1 From 1f863c789df23bddd7b9b4416d27bfd4677be52e Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:38:38 +0200 Subject: [PATCH 17/61] Disco: Switch from GNOME to XFCE --- hosts/Disco.nix | 2 +- hosts/xfce.nix | 43 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 hosts/xfce.nix diff --git a/hosts/Disco.nix b/hosts/Disco.nix index 8f28c01..776df12 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -2,7 +2,7 @@ { imports = [ ./development.nix - ./gnome.nix + ./xfce.nix ./x270.nix ./scanner.nix ./printer.nix diff --git a/hosts/xfce.nix b/hosts/xfce.nix new file mode 100644 index 0000000..bc0b1a6 --- /dev/null +++ b/hosts/xfce.nix @@ -0,0 +1,43 @@ +{ config, pkgs, ... }: +{ + services.xserver = { + enable = true; + libinput.enable = true; + desktopManager = { + xfce.enable = true; + xterm.enable = false; + }; + displayManager = { + lightdm.enable = true; + defaultSession = "xfce"; + autoLogin.enable = true; + autoLogin.user = "fruchti"; + }; + }; + nixpkgs.config.pulseaudio = true; + hardware.pulseaudio.enable = true; + hardware.bluetooth.enable = true; + services.blueman.enable = true; + # environment.xfce.excludePackages = with pkgs.xfce; [ + # xfce4-terminal + # ]; + environment.systemPackages = with pkgs; [ + xfce.xfce4-whiskermenu-plugin + xfce.xfce4-pulseaudio-plugin + xfce.xfce4-volumed-pulse + xfce.xfwm4-themes + pinentry-gnome + lounge-gtk-theme + hackneyed + blueman + gnome.file-roller + ]; + security.pam.services.lightdm.enableGnomeKeyring = true; + services.gnome.gnome-keyring.enable = true; + + services.cpupower-gui.enable = true; + + programs.gnupg.agent.pinentryFlavor = "gnome3"; + services.pcscd.enable = true; + services.dbus.packages = [ pkgs.gcr ]; +} From 57f19e259f938c5dca54d81dfdb16cac9c8de369 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:40:03 +0200 Subject: [PATCH 18/61] Disco: Add mpv, video playback codecs --- hosts/Disco.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index 776df12..e47775f 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -63,7 +63,7 @@ zathura inkscape - vlc + vlc mpv a52dec gthumb gimp tenacity From b7719a75702bae6902af958065794a573b5814af Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 27 Apr 2024 14:42:07 +0200 Subject: [PATCH 19/61] Add Dune 3D Lifted from nixpkgs-unstable, but with the most recent commit of Dune 3D. --- hosts/Disco.nix | 3 +++ packages/dune3d.nix | 65 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 68 insertions(+) create mode 100644 packages/dune3d.nix diff --git a/hosts/Disco.nix b/hosts/Disco.nix index e47775f..4d74da1 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -67,9 +67,12 @@ gthumb gimp tenacity + openscad freecad solvespace + (pkgs.callPackage ../packages/dune3d.nix {}) + vscodium marktext tor-browser-bundle-bin diff --git a/packages/dune3d.nix b/packages/dune3d.nix new file mode 100644 index 0000000..32feed2 --- /dev/null +++ b/packages/dune3d.nix @@ -0,0 +1,65 @@ +{ + cmake, + eigen, + fetchFromGitHub, + glm, + gobject-introspection, + gtkmm4, + lib, + libepoxy, + librsvg, + libspnav, + libuuid, + meson, + ninja, + opencascade-occt, + pkg-config, + python3, + gcc13Stdenv, + wrapGAppsHook, +}: + +gcc13Stdenv.mkDerivation rec { + pname = "dune3d"; + version = "84c1129"; + + src = fetchFromGitHub { + owner = "dune3d"; + repo = "dune3d"; + rev = "84c11294c38b20503f480765f7226500a834ee3c"; + hash = "sha256-77V02mowDbZR2a42WDqzcwz+J4aY64yueDqPeVTpUCI="; + }; + + nativeBuildInputs = [ + gobject-introspection + meson + ninja + pkg-config + wrapGAppsHook + ]; + buildInputs = [ + cmake + eigen + glm + gtkmm4 + libepoxy + librsvg + libspnav + libuuid + opencascade-occt + (python3.withPackages (pp: [ + pp.pygobject3 + ])) + ]; + + env.CASROOT = opencascade-occt; + + meta = with lib; { + description = "3D CAD application"; + homepage = "https://dune3d.org"; + license = licenses.gpl3Plus; + mainProgram = "dune3d"; + platforms = platforms.linux; + }; +} + From 8c8fbbbff8964107d4a978d8a377b02e502be9d6 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 4 May 2024 10:32:45 +0200 Subject: [PATCH 20/61] Update Dune3D --- packages/dune3d.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/dune3d.nix b/packages/dune3d.nix index 32feed2..f32ce7c 100644 --- a/packages/dune3d.nix +++ b/packages/dune3d.nix @@ -21,13 +21,13 @@ gcc13Stdenv.mkDerivation rec { pname = "dune3d"; - version = "84c1129"; + version = "1.1.0"; src = fetchFromGitHub { owner = "dune3d"; repo = "dune3d"; - rev = "84c11294c38b20503f480765f7226500a834ee3c"; - hash = "sha256-77V02mowDbZR2a42WDqzcwz+J4aY64yueDqPeVTpUCI="; + rev = "v${version}"; + hash = "sha256-Z/kdOc/MbnnEyRsel3aZGndTAy1eCdAK0Wdta0HxaE4="; }; nativeBuildInputs = [ From 4553c49a2b840bbed8c17d16ada6c5c909b6e5af Mon Sep 17 00:00:00 2001 From: fruchti Date: Mon, 20 May 2024 14:30:47 +0200 Subject: [PATCH 21/61] Install git-lfs by default --- base/packages.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/packages.nix b/base/packages.nix index 41ae6de..5ee50a4 100644 --- a/base/packages.nix +++ b/base/packages.nix @@ -6,7 +6,7 @@ wget rsync magic-wormhole - git + git git-lfs gnupg file ripgrep From 0fe9a18a96b8bc8b588fa9299c1284ff9c89d720 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sun, 2 Jun 2024 10:21:55 +0200 Subject: [PATCH 22/61] Rupert: Add swap --- hosts/Rupert.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index aad751c..38c0cf5 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -146,6 +146,11 @@ in SUBSYSTEM=="video4linux", ATTRS{idProduct}=="0002", ATTRS{idVendor}=="1d6b", SYMLINK+="hdmi_capture" ''; + swapDevices = [{ + device = "/swapfile"; + size = 8 * 1024; + }]; + # This value determines the NixOS release from which the default # settings for stateful data, like file locations and database versions # on your system were taken. It‘s perfectly fine and recommended to leave From 4994a81881fcdd33c33acd9d6fc67a526c03b083 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sun, 2 Jun 2024 10:22:04 +0200 Subject: [PATCH 23/61] Update Nextcloud to 28 --- hosts/nextcloud.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/nextcloud.nix b/hosts/nextcloud.nix index c5ac748..b826d63 100644 --- a/hosts/nextcloud.nix +++ b/hosts/nextcloud.nix @@ -6,7 +6,7 @@ in services.nextcloud = { enable = true; https = true; - package = pkgs.nextcloud27; + package = pkgs.nextcloud28; hostName = hostName; datadir = "/data/nextcloud"; config = { From ef6974807506a7eb7ce37ecef34c890c4bedcf3e Mon Sep 17 00:00:00 2001 From: fruchti Date: Sun, 2 Jun 2024 10:25:45 +0200 Subject: [PATCH 24/61] Emitter: Make necessary changes for 24.05 --- base/defaults.nix | 2 +- base/neovim.nix | 2 +- base/xkb/default.nix | 2 +- .../public/{ => assets}/css/fonts.css | 0 .../public/{ => assets}/css/jupyter.css | 0 ...-code-v21-latin-ext_latin_greek_cyrillic-700.eot | Bin ...-code-v21-latin-ext_latin_greek_cyrillic-700.svg | 0 ...-code-v21-latin-ext_latin_greek_cyrillic-700.ttf | Bin ...code-v21-latin-ext_latin_greek_cyrillic-700.woff | Bin ...ode-v21-latin-ext_latin_greek_cyrillic-700.woff2 | Bin ...e-v21-latin-ext_latin_greek_cyrillic-regular.eot | Bin ...e-v21-latin-ext_latin_greek_cyrillic-regular.svg | 0 ...e-v21-latin-ext_latin_greek_cyrillic-regular.ttf | Bin ...-v21-latin-ext_latin_greek_cyrillic-regular.woff | Bin ...v21-latin-ext_latin_greek_cyrillic-regular.woff2 | Bin .../fonts/hammersmith-one-v17-latin-regular.eot | Bin .../fonts/hammersmith-one-v17-latin-regular.svg | 0 .../fonts/hammersmith-one-v17-latin-regular.ttf | Bin .../fonts/hammersmith-one-v17-latin-regular.woff | Bin .../fonts/hammersmith-one-v17-latin-regular.woff2 | Bin ...lkorn-v21-latin-ext_latin_greek_cyrillic-700.eot | Bin ...lkorn-v21-latin-ext_latin_greek_cyrillic-700.svg | 0 ...lkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf | Bin ...korn-v21-latin-ext_latin_greek_cyrillic-700.woff | Bin ...orn-v21-latin-ext_latin_greek_cyrillic-700.woff2 | Bin ...v21-latin-ext_latin_greek_cyrillic-700italic.eot | Bin ...v21-latin-ext_latin_greek_cyrillic-700italic.svg | 0 ...v21-latin-ext_latin_greek_cyrillic-700italic.ttf | Bin ...21-latin-ext_latin_greek_cyrillic-700italic.woff | Bin ...1-latin-ext_latin_greek_cyrillic-700italic.woff2 | Bin ...rn-v21-latin-ext_latin_greek_cyrillic-italic.eot | Bin ...rn-v21-latin-ext_latin_greek_cyrillic-italic.svg | 0 ...rn-v21-latin-ext_latin_greek_cyrillic-italic.ttf | Bin ...n-v21-latin-ext_latin_greek_cyrillic-italic.woff | Bin ...-v21-latin-ext_latin_greek_cyrillic-italic.woff2 | Bin ...n-v21-latin-ext_latin_greek_cyrillic-regular.eot | Bin ...n-v21-latin-ext_latin_greek_cyrillic-regular.svg | 0 ...n-v21-latin-ext_latin_greek_cyrillic-regular.ttf | Bin ...-v21-latin-ext_latin_greek_cyrillic-regular.woff | Bin ...v21-latin-ext_latin_greek_cyrillic-regular.woff2 | Bin .../public/{ => assets}/img/apple-touch-icon.png | Bin .../public/{ => assets}/img/avatar_default.png | Bin .../public/{ => assets}/img/favicon.png | Bin .../public/{ => assets}/img/favicon.svg | 0 .../forgejo-custom/public/{ => assets}/img/logo.png | Bin .../forgejo-custom/public/{ => assets}/img/logo.svg | 0 46 files changed, 3 insertions(+), 3 deletions(-) rename hosts/forgejo-custom/public/{ => assets}/css/fonts.css (100%) rename hosts/forgejo-custom/public/{ => assets}/css/jupyter.css (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/hammersmith-one-v17-latin-regular.eot (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/hammersmith-one-v17-latin-regular.svg (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/hammersmith-one-v17-latin-regular.ttf (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/hammersmith-one-v17-latin-regular.woff (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/hammersmith-one-v17-latin-regular.woff2 (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff (100%) rename hosts/forgejo-custom/public/{ => assets}/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 (100%) rename hosts/forgejo-custom/public/{ => assets}/img/apple-touch-icon.png (100%) rename hosts/forgejo-custom/public/{ => assets}/img/avatar_default.png (100%) rename hosts/forgejo-custom/public/{ => assets}/img/favicon.png (100%) rename hosts/forgejo-custom/public/{ => assets}/img/favicon.svg (100%) rename hosts/forgejo-custom/public/{ => assets}/img/logo.png (100%) rename hosts/forgejo-custom/public/{ => assets}/img/logo.svg (100%) diff --git a/base/defaults.nix b/base/defaults.nix index a3f743d..0a52911 100644 --- a/base/defaults.nix +++ b/base/defaults.nix @@ -3,7 +3,7 @@ config = lib.mkDefault { i18n.defaultLocale = "en_GB.UTF-8"; console.keyMap = "us"; - services.xserver.layout = "us-fruchti"; + services.xserver.xkb.layout = "us-fruchti"; services.openssh = { enable = true; settings = { diff --git a/base/neovim.nix b/base/neovim.nix index 59fcc51..2838321 100644 --- a/base/neovim.nix +++ b/base/neovim.nix @@ -19,7 +19,7 @@ changeColorScheme-vim vim-dispatch vimtex - suda-vim + vim-suda ]; opt = []; }; diff --git a/base/xkb/default.nix b/base/xkb/default.nix index fc97d17..5c9e6c1 100644 --- a/base/xkb/default.nix +++ b/base/xkb/default.nix @@ -1,6 +1,6 @@ { ... }: { - services.xserver.extraLayouts = { + services.xserver.xkb.extraLayouts = { de-x270 = { description = "DE layout with some small changes for Thinkpad X270"; languages = [ "deu" ]; diff --git a/hosts/forgejo-custom/public/css/fonts.css b/hosts/forgejo-custom/public/assets/css/fonts.css similarity index 100% rename from hosts/forgejo-custom/public/css/fonts.css rename to hosts/forgejo-custom/public/assets/css/fonts.css diff --git a/hosts/forgejo-custom/public/css/jupyter.css b/hosts/forgejo-custom/public/assets/css/jupyter.css similarity index 100% rename from hosts/forgejo-custom/public/css/jupyter.css rename to hosts/forgejo-custom/public/assets/css/jupyter.css diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.eot diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.svg diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.ttf diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-700.woff2 diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.eot diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.svg diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.ttf diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff diff --git a/hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 b/hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 similarity index 100% rename from hosts/forgejo-custom/public/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 rename to hosts/forgejo-custom/public/assets/fonts/fira-code-v21-latin-ext_latin_greek_cyrillic-regular.woff2 diff --git a/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.eot b/hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.eot similarity index 100% rename from hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.eot rename to hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.eot diff --git a/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.svg b/hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.svg similarity index 100% rename from hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.svg rename to hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.svg diff --git a/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.ttf b/hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.ttf similarity index 100% rename from hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.ttf rename to hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.ttf diff --git a/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.woff b/hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.woff similarity index 100% rename from hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.woff rename to hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.woff diff --git a/hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.woff2 b/hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.woff2 similarity index 100% rename from hosts/forgejo-custom/public/fonts/hammersmith-one-v17-latin-regular.woff2 rename to hosts/forgejo-custom/public/assets/fonts/hammersmith-one-v17-latin-regular.woff2 diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.eot diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.svg diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.ttf diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700.woff2 diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.eot diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.svg diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.ttf diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-700italic.woff2 diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.eot diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.svg diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.ttf diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-italic.woff2 diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.eot diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.svg diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.ttf diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff diff --git a/hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 b/hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 similarity index 100% rename from hosts/forgejo-custom/public/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 rename to hosts/forgejo-custom/public/assets/fonts/vollkorn-v21-latin-ext_latin_greek_cyrillic-regular.woff2 diff --git a/hosts/forgejo-custom/public/img/apple-touch-icon.png b/hosts/forgejo-custom/public/assets/img/apple-touch-icon.png similarity index 100% rename from hosts/forgejo-custom/public/img/apple-touch-icon.png rename to hosts/forgejo-custom/public/assets/img/apple-touch-icon.png diff --git a/hosts/forgejo-custom/public/img/avatar_default.png b/hosts/forgejo-custom/public/assets/img/avatar_default.png similarity index 100% rename from hosts/forgejo-custom/public/img/avatar_default.png rename to hosts/forgejo-custom/public/assets/img/avatar_default.png diff --git a/hosts/forgejo-custom/public/img/favicon.png b/hosts/forgejo-custom/public/assets/img/favicon.png similarity index 100% rename from hosts/forgejo-custom/public/img/favicon.png rename to hosts/forgejo-custom/public/assets/img/favicon.png diff --git a/hosts/forgejo-custom/public/img/favicon.svg b/hosts/forgejo-custom/public/assets/img/favicon.svg similarity index 100% rename from hosts/forgejo-custom/public/img/favicon.svg rename to hosts/forgejo-custom/public/assets/img/favicon.svg diff --git a/hosts/forgejo-custom/public/img/logo.png b/hosts/forgejo-custom/public/assets/img/logo.png similarity index 100% rename from hosts/forgejo-custom/public/img/logo.png rename to hosts/forgejo-custom/public/assets/img/logo.png diff --git a/hosts/forgejo-custom/public/img/logo.svg b/hosts/forgejo-custom/public/assets/img/logo.svg similarity index 100% rename from hosts/forgejo-custom/public/img/logo.svg rename to hosts/forgejo-custom/public/assets/img/logo.svg From 76cabab60a7e8543773477c3f9a83153bf9c854c Mon Sep 17 00:00:00 2001 From: fruchti Date: Sun, 2 Jun 2024 11:06:30 +0200 Subject: [PATCH 25/61] Rupert: Adapt for 24.05 --- hosts/bspwm.nix | 8 +++++--- hosts/nextcloud.nix | 10 ++++++---- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/hosts/bspwm.nix b/hosts/bspwm.nix index dbf37a4..d32093a 100644 --- a/hosts/bspwm.nix +++ b/hosts/bspwm.nix @@ -4,12 +4,14 @@ enable = true; windowManager.bspwm.enable = true; displayManager = { - defaultSession = "none+bspwm"; lightdm.enable = true; - autoLogin.enable = true; - autoLogin.user = "waldi"; }; }; + services.displayManager = { + defaultSession = "none+bspwm"; + autoLogin.enable = true; + autoLogin.user = "waldi"; + }; services.unclutter-xfixes = { enable = true; diff --git a/hosts/nextcloud.nix b/hosts/nextcloud.nix index b826d63..5a46d2e 100644 --- a/hosts/nextcloud.nix +++ b/hosts/nextcloud.nix @@ -9,14 +9,16 @@ in package = pkgs.nextcloud28; hostName = hostName; datadir = "/data/nextcloud"; + settings = { + trusted_domains = [ + ((lib.toLower config.networking.hostName) + ".lan") + (lib.toLower config.networking.hostName) + ]; + }; config = { dbtype = "pgsql"; dbhost = "/run/postgresql"; adminpassFile = "/secrets/nextcloud_admin_password.txt"; - extraTrustedDomains = [ - ((lib.toLower config.networking.hostName) + ".lan") - (lib.toLower config.networking.hostName) - ]; }; caching.redis = true; }; From f0fa05faecbec2de9ee2219ca899c5bbef5c9e53 Mon Sep 17 00:00:00 2001 From: fruchti Date: Tue, 19 Nov 2024 08:52:46 +0100 Subject: [PATCH 26/61] Tunnelled burp: Add more logging --- hosts/Emitter.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hosts/Emitter.nix b/hosts/Emitter.nix index fac76c3..6ec357e 100644 --- a/hosts/Emitter.nix +++ b/hosts/Emitter.nix @@ -98,9 +98,12 @@ cat > $out/sbin/burp <<-EOF #!/${pkgs.bash}/bin/bash set -e + echo "Ensuring rupert.gvfr.de is up." ${pkgs.dig}/bin/nslookup rupert.gvfr.de ${pkgs.unixtools.ping}/bin/ping -c1 rupert.gvfr.de >/dev/null + echo "Opening SSH tunnel." ${pkgs.openssh}/bin/ssh -i /secrets/id_burp_remote -o IdentitiesOnly=yes -o ExitOnForwardFailure=yes -L 4971:localhost:4971 burp-remote@rupert.gvfr.de -f true + echo "Beginning backup operation." $out/sbin/burp-untunneled \$@ EOF chmod +x $out/sbin/burp From e0b415bb58005658e19a38fe431112b541fc878b Mon Sep 17 00:00:00 2001 From: fruchti Date: Sun, 2 Jun 2024 11:12:20 +0200 Subject: [PATCH 27/61] Upgrade Nextcloud to 29 --- hosts/nextcloud.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/nextcloud.nix b/hosts/nextcloud.nix index 5a46d2e..2beefe5 100644 --- a/hosts/nextcloud.nix +++ b/hosts/nextcloud.nix @@ -6,7 +6,7 @@ in services.nextcloud = { enable = true; https = true; - package = pkgs.nextcloud28; + package = pkgs.nextcloud29; hostName = hostName; datadir = "/data/nextcloud"; settings = { From 078e30a06a1f8690ed80cba63a07b275af14cbd3 Mon Sep 17 00:00:00 2001 From: fruchti Date: Tue, 4 Jun 2024 21:52:57 +0200 Subject: [PATCH 28/61] Disco: Add changes for 24.05 --- hosts/Disco.nix | 2 +- hosts/xfce.nix | 14 ++++++++------ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index 4d74da1..5703b5b 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -11,7 +11,7 @@ boot.loader.systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = true; console.keyMap = "de"; - services.xserver.layout = "de-x270"; + services.xserver.xkb.layout = "de-x270"; i18n.defaultLocale = "de_DE.UTF-8"; networking.hostName = "Disco"; networking.networkmanager.enable = true; diff --git a/hosts/xfce.nix b/hosts/xfce.nix index bc0b1a6..42d0d2f 100644 --- a/hosts/xfce.nix +++ b/hosts/xfce.nix @@ -2,18 +2,20 @@ { services.xserver = { enable = true; - libinput.enable = true; desktopManager = { xfce.enable = true; xterm.enable = false; }; displayManager = { lightdm.enable = true; - defaultSession = "xfce"; - autoLogin.enable = true; - autoLogin.user = "fruchti"; }; }; + services.displayManager = { + defaultSession = "xfce"; + autoLogin.enable = true; + autoLogin.user = "fruchti"; + }; + services.libinput.enable = true; nixpkgs.config.pulseaudio = true; hardware.pulseaudio.enable = true; hardware.bluetooth.enable = true; @@ -26,7 +28,7 @@ xfce.xfce4-pulseaudio-plugin xfce.xfce4-volumed-pulse xfce.xfwm4-themes - pinentry-gnome + pinentry-gtk2 lounge-gtk-theme hackneyed blueman @@ -37,7 +39,7 @@ services.cpupower-gui.enable = true; - programs.gnupg.agent.pinentryFlavor = "gnome3"; + programs.gnupg.agent.pinentryPackage = pkgs.pinentry-gtk2; services.pcscd.enable = true; services.dbus.packages = [ pkgs.gcr ]; } From 8d0b20c538aaf0ec0eb98b8e1284b43552908f1a Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 25 Jan 2025 10:47:47 +0100 Subject: [PATCH 29/61] =?UTF-8?q?Remove=20dune3d=20package=20(it=E2=80=99s?= =?UTF-8?q?=20in=20nixpkgs=20now)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hosts/Disco.nix | 2 +- packages/dune3d.nix | 65 --------------------------------------------- 2 files changed, 1 insertion(+), 66 deletions(-) delete mode 100644 packages/dune3d.nix diff --git a/hosts/Disco.nix b/hosts/Disco.nix index 5703b5b..fffb439 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -71,7 +71,7 @@ openscad freecad solvespace - (pkgs.callPackage ../packages/dune3d.nix {}) + dune3d vscodium marktext diff --git a/packages/dune3d.nix b/packages/dune3d.nix deleted file mode 100644 index f32ce7c..0000000 --- a/packages/dune3d.nix +++ /dev/null @@ -1,65 +0,0 @@ -{ - cmake, - eigen, - fetchFromGitHub, - glm, - gobject-introspection, - gtkmm4, - lib, - libepoxy, - librsvg, - libspnav, - libuuid, - meson, - ninja, - opencascade-occt, - pkg-config, - python3, - gcc13Stdenv, - wrapGAppsHook, -}: - -gcc13Stdenv.mkDerivation rec { - pname = "dune3d"; - version = "1.1.0"; - - src = fetchFromGitHub { - owner = "dune3d"; - repo = "dune3d"; - rev = "v${version}"; - hash = "sha256-Z/kdOc/MbnnEyRsel3aZGndTAy1eCdAK0Wdta0HxaE4="; - }; - - nativeBuildInputs = [ - gobject-introspection - meson - ninja - pkg-config - wrapGAppsHook - ]; - buildInputs = [ - cmake - eigen - glm - gtkmm4 - libepoxy - librsvg - libspnav - libuuid - opencascade-occt - (python3.withPackages (pp: [ - pp.pygobject3 - ])) - ]; - - env.CASROOT = opencascade-occt; - - meta = with lib; { - description = "3D CAD application"; - homepage = "https://dune3d.org"; - license = licenses.gpl3Plus; - mainProgram = "dune3d"; - platforms = platforms.linux; - }; -} - From 6021552b816084c71cb21e0c8b972a7adae08d96 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 25 Jan 2025 10:48:27 +0100 Subject: [PATCH 30/61] Disco: Install darktable --- hosts/Disco.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index fffb439..eaaa260 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -66,6 +66,7 @@ vlc mpv a52dec gthumb gimp + darktable tenacity openscad From 65eff9fab96e2bcf182e59fd83937546776119bf Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 25 Jan 2025 10:48:41 +0100 Subject: [PATCH 31/61] Disco: Install KiCad --- hosts/Disco.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index eaaa260..fe112de 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -80,6 +80,7 @@ libreoffice-fresh tdesktop horizon-eda + kicad-small cura pulseview nextcloud-client From b13c5aecaa79a544acd9da6dbc7275e14a7195e0 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 25 Jan 2025 10:49:29 +0100 Subject: [PATCH 32/61] Disco: Fix steam --- hosts/Disco.nix | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index fe112de..3e2d7e1 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -117,8 +117,9 @@ programs.steam = { enable = true; - # remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play - # dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server + remotePlay.openFirewall = true; + dedicatedServer.openFirewall = true; + localNetworkGameTransfers.openFirewall = true; }; nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ @@ -126,6 +127,7 @@ "steam-original" "steam-runtime" "steam-run" + "steam-unwrapped" ]; fileSystems."/windows" = { From b9e9b29cb32652fb29e13f414385f4eb75776d5a Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 25 Jan 2025 10:50:33 +0100 Subject: [PATCH 33/61] Add clamav module --- hosts/Disco.nix | 1 + hosts/clamav.nix | 9 +++++++++ 2 files changed, 10 insertions(+) create mode 100644 hosts/clamav.nix diff --git a/hosts/Disco.nix b/hosts/Disco.nix index 3e2d7e1..790cc05 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -6,6 +6,7 @@ ./x270.nix ./scanner.nix ./printer.nix + # ./clamav.nix ]; boot.loader.systemd-boot.enable = true; diff --git a/hosts/clamav.nix b/hosts/clamav.nix new file mode 100644 index 0000000..a6c9c79 --- /dev/null +++ b/hosts/clamav.nix @@ -0,0 +1,9 @@ +{ pkgs, ... }: +{ + environment.systemPackages = [ + pkgs.clamav + ]; + services.clamav.daemon.enable = true; + + services.clamav.updater.enable = true; +} From 9447e77b5acb643c6bdfcb93d930c82de15d98ad Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 25 Jan 2025 21:41:14 +0100 Subject: [PATCH 34/61] Rupert: Replace hardware.opengl with .graphics --- hosts/Rupert.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index 38c0cf5..627b201 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -25,7 +25,7 @@ in nixpkgs.config.packageOverrides = pkgs: { vaapiIntel = pkgs.vaapiIntel.override { enableHybridCodec = true; }; }; - hardware.opengl = { + hardware.graphics = { enable = true; extraPackages = with pkgs; [ (if (lib.versionOlder (lib.versions.majorMinor lib.version) "23.11") then vaapiIntel else intel-vaapi-driver) From a29e70750f97a2361afa4aa1670c021410917ad5 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 25 Jan 2025 21:41:52 +0100 Subject: [PATCH 35/61] Fix dyndns package path for 24.11 --- options/dyndns.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/options/dyndns.nix b/options/dyndns.nix index 09ea088..90aac18 100644 --- a/options/dyndns.nix +++ b/options/dyndns.nix @@ -63,7 +63,7 @@ in dyndns_user="${cfg.username}" dyndns_password="$(cat "${cfg.passwordFile}")" - new_ip=$(${pkgs.iproute}/bin/ip -6 a show scope global -temporary dev "$interface" | ${pkgs.gnused}/bin/sed -n -E 's/^\ *inet6\ (2001(:[0-9a-f]+)+).*$/\1/p' | head -1) + new_ip=$(${pkgs.iproute2}/bin/ip -6 a show scope global -temporary dev "$interface" | ${pkgs.gnused}/bin/sed -n -E 's/^\ *inet6\ (2001(:[0-9a-f]+)+).*$/\1/p' | head -1) if [ -z "$new_ip" ] ; then echo "Could not determine IP address." From 9c39dc18d02a176497a1d6f024befb0a2677c8a1 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 25 Jan 2025 21:42:12 +0100 Subject: [PATCH 36/61] MPD: Explicitly disable pipewire to use pulseaudio --- hosts/mpd.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/mpd.nix b/hosts/mpd.nix index 29ad661..ca9262e 100644 --- a/hosts/mpd.nix +++ b/hosts/mpd.nix @@ -44,6 +44,7 @@ in tcp.enable = true; tcp.anonymousClients.allowedIpRanges = [ "127.0.0.1" ]; }; + services.pipewire.enable = false; users.extraGroups.pulse-access = { members = [ "mpd" ]; From e88e24991f1bd68e6c248248e8b1082aca1922b5 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sat, 25 Jan 2025 22:33:24 +0100 Subject: [PATCH 37/61] Auto-upgrade: Also catch evaluation warnings --- options/auto-upgrade.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/options/auto-upgrade.nix b/options/auto-upgrade.nix index 0809236..9a84200 100644 --- a/options/auto-upgrade.nix +++ b/options/auto-upgrade.nix @@ -178,7 +178,7 @@ in upgrade_output="$(cat "$output_file")" rm -f "$output_file" - possible_warnings="$(grep -e "^\(warning\|trace\):" <<<"$upgrade_output" || true)" + possible_warnings="$(grep -e "^\(warning\|trace\|evaluation warning\):" <<<"$upgrade_output" || true)" if [ "$possible_warnings" != "" ] ; then send_email=yes email_subject_additions="$email_subject_additions with warnings" From c860fef7aa708587ecc6517bc6a5bda8d7e5c6df Mon Sep 17 00:00:00 2001 From: fruchti Date: Sun, 2 Feb 2025 20:42:38 +0100 Subject: [PATCH 38/61] Upgrade Nextcloud to 30 --- hosts/nextcloud.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/nextcloud.nix b/hosts/nextcloud.nix index 2beefe5..7734950 100644 --- a/hosts/nextcloud.nix +++ b/hosts/nextcloud.nix @@ -6,7 +6,7 @@ in services.nextcloud = { enable = true; https = true; - package = pkgs.nextcloud29; + package = pkgs.nextcloud30; hostName = hostName; datadir = "/data/nextcloud"; settings = { From 44f98a69d18b7449ee601615323d79e47d5ca256 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 7 Mar 2025 08:37:33 +0100 Subject: [PATCH 39/61] Forgejo: Set nginx request size for git-lfs --- hosts/forgejo.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hosts/forgejo.nix b/hosts/forgejo.nix index ce2ff36..6b2145d 100644 --- a/hosts/forgejo.nix +++ b/hosts/forgejo.nix @@ -123,6 +123,10 @@ in enableACME = true; forceSSL = true; locations."/".proxyPass = "http://localhost:3001/"; + extraConfig = '' + # Maximum upload file size for git-lfs + client_max_body_size 100M; + ''; }; }; From 1e84717fd6b93d3dfd90b5d148734dcdeb1f52f2 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 7 Mar 2025 08:38:10 +0100 Subject: [PATCH 40/61] Emitter: Ensure IPv6 for burp backups to Rupert --- hosts/Emitter.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/Emitter.nix b/hosts/Emitter.nix index 6ec357e..f0e9c2a 100644 --- a/hosts/Emitter.nix +++ b/hosts/Emitter.nix @@ -102,7 +102,7 @@ ${pkgs.dig}/bin/nslookup rupert.gvfr.de ${pkgs.unixtools.ping}/bin/ping -c1 rupert.gvfr.de >/dev/null echo "Opening SSH tunnel." - ${pkgs.openssh}/bin/ssh -i /secrets/id_burp_remote -o IdentitiesOnly=yes -o ExitOnForwardFailure=yes -L 4971:localhost:4971 burp-remote@rupert.gvfr.de -f true + ${pkgs.openssh}/bin/ssh -6 -i /secrets/id_burp_remote -o IdentitiesOnly=yes -o ExitOnForwardFailure=yes -L 4971:localhost:4971 burp-remote@rupert.gvfr.de -f true echo "Beginning backup operation." $out/sbin/burp-untunneled \$@ EOF From f0e005ed7bebbcd3ea0128b94504a32424a0846d Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 7 Mar 2025 08:39:06 +0100 Subject: [PATCH 41/61] Emitter: Specify postgres version --- hosts/Emitter.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hosts/Emitter.nix b/hosts/Emitter.nix index f0e9c2a..2db269a 100644 --- a/hosts/Emitter.nix +++ b/hosts/Emitter.nix @@ -142,6 +142,8 @@ }; }; + services.postgresql.package = pkgs.postgresql_13; + # This value determines the NixOS release from which the default # settings for stateful data, like file locations and database versions # on your system were taken. It’s perfectly fine and recommended to leave From 00bf70b29ae0e7c801c9b2e3128751afefe35012 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 7 Mar 2025 08:39:44 +0100 Subject: [PATCH 42/61] Emitter: TLS-SNI forward Nextcloud traffic --- hosts/tls_sni.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/tls_sni.nix b/hosts/tls_sni.nix index ec4d7ee..be9ce62 100644 --- a/hosts/tls_sni.nix +++ b/hosts/tls_sni.nix @@ -4,6 +4,7 @@ streamConfig = '' map $ssl_preread_server_name $target_backend { md.gvfr.de rupert; + rupert.gvfr.de rupert; default localserv; } From 5585164f1f3670b41c9efdc62b2520e4ab3417d2 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sun, 30 Mar 2025 20:10:11 +0200 Subject: [PATCH 43/61] Burp server: Add new client Adelheid --- hosts/burp-server.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/burp-server.nix b/hosts/burp-server.nix index a98fc21..334a954 100644 --- a/hosts/burp-server.nix +++ b/hosts/burp-server.nix @@ -19,6 +19,7 @@ "Berthold" "Ernesto" "Emitter" + "Adelheid" ]); superClients = [ config.networking.hostName From b1cd6018baad1dd73e8d10cd6be0b633e8682b47 Mon Sep 17 00:00:00 2001 From: fruchti Date: Sun, 30 Mar 2025 20:54:22 +0200 Subject: [PATCH 44/61] Disallow auto-reboot when users are active --- hosts/Rupert.nix | 1 + options/auto-upgrade.nix | 15 +++++++++++++++ 2 files changed, 16 insertions(+) diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index 627b201..f2f822f 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -119,6 +119,7 @@ in gitPull = true; gitDeploymentKeyFile = "/secrets/ssh_id_gitea_nixos_configuration"; gitUser = "fruchti"; + rebootIgnoreUsersActive = [ "waldi" ]; }; # systemd.services.nixos-upgrade.onFailure = lib.mkIf config.system.autoUpgrade.enable [ "status-email@%n.service" ]; diff --git a/options/auto-upgrade.nix b/options/auto-upgrade.nix index 9a84200..d0f9829 100644 --- a/options/auto-upgrade.nix +++ b/options/auto-upgrade.nix @@ -36,6 +36,13 @@ in User used for the `git pull` operation (if `gitPull` is enabled). ''; }; + rebootIgnoreUsersActive = mkOption { + type = types.listOf types.str; + default = []; + description = mdDoc '' + If reboots are allowed, active users will prohibit a reboot. Users listed here are ignored from that check. + ''; + }; }; config = mkIf cfg.enable { @@ -156,6 +163,14 @@ in EOF )" activate_configuration="no" + + # Check if any user sessions are open + active_users=$(users | tr ' ' '\n' | sort | uniq | grep -vE '^(${concatStringsSep "|" cfg.rebootIgnoreUsersActive})$') + if [ "$reboot_allowed" = "yes" ] && [ -n "$active_users" ] ; then + reboot_allowed=no + email_body="$(printf "%s\n%s\n%s" "$email_body" "The system cannot reboot since the following users are active:" "$active_users")" + fi + if [ "$reboot_allowed" = "yes" ] && [ $exit_code -eq 0 ] ; then email_body="$(printf "%s\n%s" "$email_body" "The system will reboot now.")" do_reboot="yes" From f7fba79b6a97e6bf43fa11adf70cb83f0b8aa460 Mon Sep 17 00:00:00 2001 From: fruchti Date: Mon, 7 Apr 2025 09:13:58 +0200 Subject: [PATCH 45/61] =?UTF-8?q?Nextcloud:=20Don=E2=80=99t=20blacklist=20?= =?UTF-8?q?any=20files=20server-side?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Attempt to synchronise .htaccess files. Doesn’t seem to work, though. --- hosts/nextcloud.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/nextcloud.nix b/hosts/nextcloud.nix index 7734950..f916038 100644 --- a/hosts/nextcloud.nix +++ b/hosts/nextcloud.nix @@ -14,6 +14,7 @@ in ((lib.toLower config.networking.hostName) + ".lan") (lib.toLower config.networking.hostName) ]; + blacklisted_files = []; }; config = { dbtype = "pgsql"; From 84793a16c763e1327e991ce20226b2f57aacb0ab Mon Sep 17 00:00:00 2001 From: fruchti Date: Mon, 7 Apr 2025 09:14:35 +0200 Subject: [PATCH 46/61] Nextcloud: Add trash file retention policy --- hosts/nextcloud.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/nextcloud.nix b/hosts/nextcloud.nix index f916038..fe1a9cb 100644 --- a/hosts/nextcloud.nix +++ b/hosts/nextcloud.nix @@ -15,6 +15,7 @@ in (lib.toLower config.networking.hostName) ]; blacklisted_files = []; + trashbin_retention_obligation = "auto, 14"; }; config = { dbtype = "pgsql"; From 2d6a9d987682daad03eea17c86ad0c36b1ac22d3 Mon Sep 17 00:00:00 2001 From: fruchti Date: Mon, 7 Apr 2025 09:15:57 +0200 Subject: [PATCH 47/61] Rupert: Configure BluRay playback --- hosts/Rupert.nix | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index f2f822f..451ac50 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -17,6 +17,17 @@ in # ./open-pgsql.nix ]; + nixpkgs.overlays = [ + ( + self: super: { + libbluray = super.libbluray.override { + withAACS = true; + withBDplus = true; + }; + } + ) + ]; + boot.loader.systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = true; boot.kernelParams = [ "acpi=force" "reboot=bios" ]; From 567e13ec7101e56ae872e293bc75a82ec1e8a9ef Mon Sep 17 00:00:00 2001 From: fruchti Date: Mon, 7 Apr 2025 09:16:18 +0200 Subject: [PATCH 48/61] Rupert: Add beesd --- hosts/Rupert.nix | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index 451ac50..08b79b6 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -146,6 +146,22 @@ in }; }; }; + services.beesd = { + filesystems = { + "data" = { + spec = "/data"; + hashTableSizeMB = 1024; + verbosity = "alert"; + }; + "backup-disk" = { + spec = "/mnt/backup"; + hashTableSizeMB = 1024; + verbosity = "alert"; + }; + }; + }; + # Don’t start automatically + systemd.services."beesd@backup-disk".wantedBy = lib.mkForce []; security.acme = { defaults = { From 79034afe61ab3ceae4f41cb1df067aec9e9d960d Mon Sep 17 00:00:00 2001 From: fruchti Date: Mon, 7 Apr 2025 09:17:21 +0200 Subject: [PATCH 49/61] Rupert: Delete some old comments --- hosts/Rupert.nix | 8 -------- 1 file changed, 8 deletions(-) diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index 08b79b6..3823412 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -99,9 +99,6 @@ in enableSSHSupport = true; }; - # List services that you want to enable: - - # Enable the OpenSSH daemon. services.openssh = { enable = true; settings = { @@ -118,11 +115,6 @@ in 4971 # BURP ]; - # Copy the NixOS configuration file and link it from the resulting system - # (/run/current-system/configuration.nix). This is useful in case you - # accidentally delete configuration.nix. - # system.copySystemConfiguration = true; - system.autoUpgrade = { enable = true; allowReboot = true; From 36eed4c3d2310cc4a1e77d3b5018666802159a13 Mon Sep 17 00:00:00 2001 From: fruchti Date: Mon, 7 Apr 2025 09:27:50 +0200 Subject: [PATCH 50/61] Rupert: Install smartmontools --- hosts/Rupert.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index 3823412..1c0d758 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -71,6 +71,7 @@ in environment.systemPackages = with pkgs; [ ntfsprogs + smartmontools texlive.combined.scheme-full ncmpcpp ]; From 81cf231f68d63a54a8c4da90226c8667c4f41727 Mon Sep 17 00:00:00 2001 From: fruchti Date: Thu, 17 Apr 2025 11:37:33 +0200 Subject: [PATCH 51/61] Fix email sending --- options/email.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/options/email.nix b/options/email.nix index 62f631c..244e891 100644 --- a/options/email.nix +++ b/options/email.nix @@ -1,4 +1,4 @@ -{ config, lib, ... }: +{ config, lib, pkgs, ... }: with lib; let cfg = config.email; @@ -37,7 +37,7 @@ in default = { auth = true; host = "gvfr.de"; - passwordeval = "cat /secrets/email_password.txt"; + passwordeval = "${pkgs.coreutils}/bin/cat /secrets/email_password.txt"; user = cfg.fromAddress; from = cfg.fromAddress; port = 465; From a002c1476dfb2977d91f6de677873c1050f0a09c Mon Sep 17 00:00:00 2001 From: fruchti Date: Thu, 17 Apr 2025 12:16:36 +0200 Subject: [PATCH 52/61] Rupert: Enable smartd --- hosts/Rupert.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/hosts/Rupert.nix b/hosts/Rupert.nix index 1c0d758..ef0fa9c 100644 --- a/hosts/Rupert.nix +++ b/hosts/Rupert.nix @@ -128,6 +128,16 @@ in # systemd.services.nixos-upgrade.onFailure = lib.mkIf config.system.autoUpgrade.enable [ "status-email@%n.service" ]; + services.smartd = { + enable = true; + notifications.x11.enable = false; + notifications.mail = { + enable = true; + sender = config.email.fromAddress; + recipient = config.email.adminEmail; + mailer = "${pkgs.system-sendmail}/bin/sendmail"; + }; + }; services.btrfsScrub = { enable = true; paths = { From e5f404f9f78f806cca99e88ccbe4ca77af44d764 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 2 May 2025 17:56:48 +0200 Subject: [PATCH 53/61] Disco: Install exiftool --- hosts/Disco.nix | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index 790cc05..ff10ad5 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -45,8 +45,7 @@ htop ncmpcpp usbutils # lsusb etc. - file - binwalk + file exiftool binwalk shellcheck wine From b573aa40fc9aa44177e7631802e744a58b8d4768 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 2 May 2025 17:57:11 +0200 Subject: [PATCH 54/61] Disco: Install wineWow instead of wine --- hosts/Disco.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index ff10ad5..5e08291 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -48,7 +48,7 @@ file exiftool binwalk shellcheck - wine + #wine wineWowPackages.stable winePackages.fonts pavucontrol From e2466b628a16dcca12e12b3319d52cda3360ba74 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 2 May 2025 17:57:37 +0200 Subject: [PATCH 55/61] Disco: Install cura via AppImage --- hosts/Disco.nix | 3 +- packages/cura-appimage.nix | 131 +++++++++++++++++++++++++++++++++++++ 2 files changed, 133 insertions(+), 1 deletion(-) create mode 100644 packages/cura-appimage.nix diff --git a/hosts/Disco.nix b/hosts/Disco.nix index 5e08291..1854d55 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -81,7 +81,8 @@ tdesktop horizon-eda kicad-small - cura + # cura + (pkgs.callPackage ../packages/cura-appimage.nix {}) pulseview nextcloud-client ]; diff --git a/packages/cura-appimage.nix b/packages/cura-appimage.nix new file mode 100644 index 0000000..9de879e --- /dev/null +++ b/packages/cura-appimage.nix @@ -0,0 +1,131 @@ +{ + lib, + stdenv, + stdenvNoCC, + fetchurl, + writeScriptBin, + appimageTools, + copyDesktopItems, + makeDesktopItem, + nix-update-script, + wrapGAppsHook3, +}: + +stdenvNoCC.mkDerivation rec { + pname = "cura-appimage"; + version = "5.9.0"; + + # Give some good names so the intermediate packages are easy + # to recognise by name in the Nix store. + appimageBinName = "cura-appimage-tools-output"; + wrapperScriptName = "${pname}-wrapper-script"; + + src = fetchurl { + url = "https://github.com/Ultimaker/Cura/releases/download/${version}/Ultimaker-Cura-${version}-linux-X64.AppImage"; + hash = "sha256-STtVeM4Zs+PVSRO3cI0LxnjRDhOxSlttZF+2RIXnAp4="; + }; + + appimageContents = appimageTools.extract { + inherit pname version src; + }; + + curaAppimageToolsWrapped = appimageTools.wrapType2 { + inherit src; + # For `appimageTools.wrapType2`, `pname` determines the binary's name in `bin/`. + pname = appimageBinName; + inherit version; + extraPkgs = _: [ ]; + }; + + # The `QT_QPA_PLATFORM=xcb` fixes Wayland support, see https://github.com/NixOS/nixpkgs/issues/186570#issuecomment-2526277637 + # The `GTK_USE_PORTAL=1` fixes file dialog issues under Gnome, see https://github.com/NixOS/nixpkgs/pull/372614#issuecomment-2585663161 + script = writeScriptBin wrapperScriptName '' + #!${stdenv.shell} + # AppImage version of Cura loses current working directory and treats all paths relateive to $HOME. + # So we convert each of the files passed as argument to an absolute path. + # This fixes use cases like `cd /path/to/my/files; cura mymodel.stl anothermodel.stl`. + + args=() + for a in "$@"; do + if [ -e "$a" ]; then + a="$(realpath "$a")" + fi + args+=("$a") + done + QT_QPA_PLATFORM=xcb GTK_USE_PORTAL=1 exec "${curaAppimageToolsWrapped}/bin/${appimageBinName}" "''${args[@]}" + ''; + + dontUnpack = true; + + nativeBuildInputs = [ + copyDesktopItems + wrapGAppsHook3 + ]; + desktopItems = [ + # Based on upstream. + # https://github.com/Ultimaker/Cura/blob/382b98e8b0c910fdf8b1509557ae8afab38f1817/packaging/AppImage/cura.desktop.jinja + (makeDesktopItem { + name = "cura"; + desktopName = "UltiMaker Cura"; + genericName = "3D Printing Software"; + comment = meta.longDescription; + exec = "cura"; + icon = "cura-icon"; + terminal = false; + type = "Application"; + mimeTypes = [ + "model/stl" + "application/vnd.ms-3mfdocument" + "application/prs.wavefront-obj" + "image/bmp" + "image/gif" + "image/jpeg" + "image/png" + "text/x-gcode" + "application/x-amf" + "application/x-ply" + "application/x-ctm" + "model/vnd.collada+xml" + "model/gltf-binary" + "model/gltf+json" + "model/vnd.collada+xml+zip" + ]; + categories = [ "Graphics" ]; + keywords = [ + "3D" + "Printing" + ]; + }) + ]; + + installPhase = '' + runHook preInstall + + mkdir -p $out/bin + cp ${script}/bin/${wrapperScriptName} $out/bin/cura + + mkdir -p $out/share/applications $out/share/icons/hicolor/128x128/apps + install -Dm644 ${appimageContents}/usr/share/icons/hicolor/128x128/apps/cura-icon.png $out/share/icons/hicolor/128x128/apps/cura-icon.png + + runHook postInstall + ''; + + passthru.updateScript = nix-update-script { extraArgs = [ "--version-regex=([56789].+)" ]; }; + + meta = { + description = "3D printing software"; + homepage = "https://github.com/ultimaker/cura"; + changelog = "https://github.com/Ultimaker/Cura/releases/tag/${version}"; + longDescription = '' + Cura converts 3D models into paths for a 3D printer. It prepares your print for maximum accuracy, minimum printing time and good reliability with many extra features that make your print come out great. + ''; + license = lib.licenses.lgpl3Plus; + platforms = [ "x86_64-linux" ]; + mainProgram = "cura"; + maintainers = with lib.maintainers; [ + pbek + nh2 + fliegendewurst + ]; + }; +} From 59c2d88171d4487a37c863860516d767d62e34a8 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 2 May 2025 18:00:54 +0200 Subject: [PATCH 56/61] Disco: Add ARM toolchain --- hosts/Disco.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index 1854d55..bfbaa3b 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -93,6 +93,8 @@ system.extraDependencies = with pkgs; [ # For various development environments gcc-arm-embedded + pkgsCross.arm-embedded.buildPackages.gcc + pkgsCross.riscv32-embedded.buildPackages.gcc gnumake ]; From 82b0e8f4eef684cd7c3d6ef11d9bc6d2c991792b Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 2 May 2025 18:01:34 +0200 Subject: [PATCH 57/61] Disco: Enable font smoothing --- hosts/Disco.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hosts/Disco.nix b/hosts/Disco.nix index bfbaa3b..f1fdcbf 100644 --- a/hosts/Disco.nix +++ b/hosts/Disco.nix @@ -192,6 +192,10 @@ size = 16 * 1024; }]; + environment.variables = { + FREETYPE_PROPERTIES = "cff:no-stem-darkening=0 autofitter:no-stem-darkening=0 type1:no-stem-darkening=0 t1cid:no-stem-darkening=0"; + }; + # This value determines the NixOS release from which the default # settings for stateful data, like file locations and database versions # on your system were taken. It‘s perfectly fine and recommended to leave From b8bd5a3f216eb4025cdb57e2ce2287ea483d31f0 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 2 May 2025 18:14:56 +0200 Subject: [PATCH 58/61] X270: Use nixos-hardware, update graphics option --- hosts/x270.nix | 27 ++++----------------------- 1 file changed, 4 insertions(+), 23 deletions(-) diff --git a/hosts/x270.nix b/hosts/x270.nix index 30f75e8..1fc9ee7 100644 --- a/hosts/x270.nix +++ b/hosts/x270.nix @@ -1,38 +1,19 @@ { lib, pkgs, ... }: { + imports = [ + + ]; hardware.trackpoint = { enable = true; sensitivity = 230; speed = 170; }; - # Ensure that trackpoint mouse buttons work after suspend without having - # to touch the trackpoint first - powerManagement = { - powerDownCommands = '' - modprobe -r psmouse - ''; - resumeCommands = '' - modprobe psmouse - ''; - }; - - services.xserver.videoDrivers = [ "modesetting" ]; - - boot.initrd.kernelModules = [ "i915" ]; - hardware.opengl = { + hardware.graphics = { enable = true; # driSupport = true; # driSupport32Bit = true; }; - environment.variables = { - VDPAU_DRIVER = "va_gl"; - }; - hardware.opengl.extraPackages = with pkgs; [ - (if (lib.versionOlder (lib.versions.majorMinor lib.version) "23.11") then vaapiIntel else intel-vaapi-driver) - libvdpau-va-gl - intel-media-driver - ]; console = { font = "Lat2-Terminus16"; From 84550fffa2f5f42b41c7f41f1663ab52e7af16f8 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 2 May 2025 18:16:54 +0200 Subject: [PATCH 59/61] Remove Horizon draw-surface patch Does not seem to be necessary any more. --- overlays/default.nix | 1 - overlays/horizon-eda.nix | 13 ------------- overlays/horizon_software_draw_surface.patch | 10 ---------- 3 files changed, 24 deletions(-) delete mode 100644 overlays/horizon-eda.nix delete mode 100644 overlays/horizon_software_draw_surface.patch diff --git a/overlays/default.nix b/overlays/default.nix index eab7738..7cd1fd2 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -2,6 +2,5 @@ { imports = [ ./burp.nix - ./horizon-eda.nix ]; } diff --git a/overlays/horizon-eda.nix b/overlays/horizon-eda.nix deleted file mode 100644 index 3022fdf..0000000 --- a/overlays/horizon-eda.nix +++ /dev/null @@ -1,13 +0,0 @@ -{ config, ... }: -{ - nixpkgs.overlays = [ - (self: super: { - horizon-eda = (super.horizon-eda.overrideAttrs (old: { - # Add an environment variable to fix redraw issues on Intel Graphics - patches = [ - ./horizon_software_draw_surface.patch - ]; - })); - }) - ]; -} diff --git a/overlays/horizon_software_draw_surface.patch b/overlays/horizon_software_draw_surface.patch deleted file mode 100644 index c44c667..0000000 --- a/overlays/horizon_software_draw_surface.patch +++ /dev/null @@ -1,10 +0,0 @@ -diff --git a/org.horizon_eda.HorizonEDA.desktop b/org.horizon_eda.HorizonEDA.desktop -index 7551df54..d8df7800 100644 ---- a/org.horizon_eda.HorizonEDA.desktop -+++ b/org.horizon_eda.HorizonEDA.desktop -@@ -5,4 +5,4 @@ Categories=Development;Engineering;Electronics; - Type=Application - Terminal=false - Icon=org.horizon_eda.HorizonEDA --Exec=horizon-eda %U -+Exec=env GDK_GL=software-draw-surface horizon-eda %U From a8922cb72d59b1c4fa30d61468cc5e975e35b0a9 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 2 May 2025 18:18:32 +0200 Subject: [PATCH 60/61] Update XFCE configuration, switch to PipeWire --- hosts/xfce.nix | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/hosts/xfce.nix b/hosts/xfce.nix index 42d0d2f..d2e996e 100644 --- a/hosts/xfce.nix +++ b/hosts/xfce.nix @@ -3,11 +3,15 @@ services.xserver = { enable = true; desktopManager = { - xfce.enable = true; + xfce= { + enable = true; + enableXfwm = true; + }; xterm.enable = false; }; displayManager = { lightdm.enable = true; + gdm.wayland = false; }; }; services.displayManager = { @@ -16,8 +20,12 @@ autoLogin.user = "fruchti"; }; services.libinput.enable = true; - nixpkgs.config.pulseaudio = true; - hardware.pulseaudio.enable = true; + services.pipewire = { + enable = true; + alsa.enable = true; + alsa.support32Bit = true; + pulse.enable = true; + }; hardware.bluetooth.enable = true; services.blueman.enable = true; # environment.xfce.excludePackages = with pkgs.xfce; [ @@ -32,7 +40,7 @@ lounge-gtk-theme hackneyed blueman - gnome.file-roller + file-roller ]; security.pam.services.lightdm.enableGnomeKeyring = true; services.gnome.gnome-keyring.enable = true; From 2fda9075b06512c5f47ca2a7c0187412504c1860 Mon Sep 17 00:00:00 2001 From: fruchti Date: Fri, 2 May 2025 18:19:26 +0200 Subject: [PATCH 61/61] Add udev rule for USB thermal printer --- base/hardware.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/base/hardware.nix b/base/hardware.nix index d7f0905..bc59584 100644 --- a/base/hardware.nix +++ b/base/hardware.nix @@ -3,5 +3,8 @@ services.udev.extraRules = '' # Keychron C2 function key fix SUBSYSTEMS=="input", ATTRS{name}=="Keychron Keychron C2", RUN+="${pkgs.bash}/bin/bash -c 'echo 0 > /sys/module/hid_apple/parameters/fnmode'" + + # EM8026 thermal printer + SUBSYSTEM=="usb", ATTRS{idVendor}=="28e9", ATTRS{idProduct}=="0289", MODE="0660", GROUP="plugdev" ''; }