diff --git a/flake.lock b/flake.lock index 68e1cc5..628cb16 100644 --- a/flake.lock +++ b/flake.lock @@ -14,11 +14,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1742246110, - "narHash": "sha256-bjJDxW3Z3clNIkgwEktWhFSpU9UyftisDfK3XYzdRps=", + "lastModified": 1740601740, + "narHash": "sha256-YQ8lMeT/KkMDavXrqPvoO6pKQdfSSAZBcNp/Cer4vWc=", "owner": "nix-community", "repo": "authentik-nix", - "rev": "04f5e14643b8b37304966767074fbe0efcadab9f", + "rev": "bfcad34becd76d148e1ad537b5dcbd58d858a5bb", "type": "github" }, "original": { @@ -30,16 +30,16 @@ "authentik-src": { "flake": false, "locked": { - "lastModified": 1742236492, - "narHash": "sha256-Uz7qldS44pxduLcYKf+cCq4WvjoslDR4PwRqivY/4uI=", + "lastModified": 1740599692, + "narHash": "sha256-KZalpsM9rvki9GD+urf8idHOEnvBJtkSvE1b2b4KL/4=", "owner": "goauthentik", "repo": "authentik", - "rev": "3adf79c4939276e108c25c719843b6174e9e22fd", + "rev": "31fe0e59234e487a42012510d1a4e4819b9aba26", "type": "github" }, "original": { "owner": "goauthentik", - "ref": "version/2025.2.2", + "ref": "version/2025.2.1", "repo": "authentik", "type": "github" } @@ -248,27 +248,6 @@ "type": "github" } }, - "home-manager": { - "inputs": { - "nixpkgs": [ - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1742234739, - "narHash": "sha256-zFL6zsf/5OztR1NSNQF33dvS1fL/BzVUjabZq4qrtY4=", - "owner": "nix-community", - "repo": "home-manager", - "rev": "f6af7280a3390e65c2ad8fd059cdc303426cbd59", - "type": "github" - }, - "original": { - "owner": "nix-community", - "ref": "release-24.11", - "repo": "home-manager", - "type": "github" - } - }, "lanzaboote": { "inputs": { "crane": "crane", @@ -299,11 +278,11 @@ "lix": { "flake": false, "locked": { - "lastModified": 1742313775, - "narHash": "sha256-qE8XqkuoWuH2np+NNGGNG8qWN2zPa0ldAM0olaySf+s=", - "rev": "6e6ff5827276ed2c4cf549b9fa898eb1e9566e57", + "lastModified": 1742165831, + "narHash": "sha256-/ssmsf50UERQNlOcUuyfvigcnCNckAhAPZMo0+Y3mdY=", + "rev": "2a336813ad2a4d64d027830507276da32927d215", "type": "tarball", - "url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/6e6ff5827276ed2c4cf549b9fa898eb1e9566e57.tar.gz?rev=6e6ff5827276ed2c4cf549b9fa898eb1e9566e57" + "url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/2a336813ad2a4d64d027830507276da32927d215.tar.gz?rev=2a336813ad2a4d64d027830507276da32927d215" }, "original": { "type": "tarball", @@ -384,65 +363,6 @@ "type": "github" } }, - "niri": { - "inputs": { - "niri-stable": "niri-stable", - "niri-unstable": "niri-unstable", - "nixpkgs": [ - "nixpkgs" - ], - "nixpkgs-stable": "nixpkgs-stable_2", - "xwayland-satellite-stable": "xwayland-satellite-stable", - "xwayland-satellite-unstable": "xwayland-satellite-unstable" - }, - "locked": { - "lastModified": 1742305115, - "narHash": "sha256-EJu/9UNo8ndiZ7AUVTazWQOA4lHUaTkorvgVExo2LLs=", - "owner": "sodiboo", - "repo": "niri-flake", - "rev": "bc4f3a4d3d0fb9be399faf525caffd5b664c5d31", - "type": "github" - }, - "original": { - "owner": "sodiboo", - "ref": "main", - "repo": "niri-flake", - "type": "github" - } - }, - "niri-stable": { - "flake": false, - "locked": { - "lastModified": 1740117926, - "narHash": "sha256-mTTHA0RAaQcdYe+9A3Jx77cmmyLFHmRoZdd8RpWa+m8=", - "owner": "YaLTeR", - "repo": "niri", - "rev": "b94a5db8790339cf9134873d8b490be69e02ac71", - "type": "github" - }, - "original": { - "owner": "YaLTeR", - "ref": "v25.02", - "repo": "niri", - "type": "github" - } - }, - "niri-unstable": { - "flake": false, - "locked": { - "lastModified": 1742276600, - "narHash": "sha256-muceB5DW++WPqrGKpX3Hkii/DNSMmFs2oQrYRYHmPiU=", - "owner": "YaLTeR", - "repo": "niri", - "rev": "e251ca7340bc71870c3a81a7ffc3d9bde58e685a", - "type": "github" - }, - "original": { - "owner": "YaLTeR", - "repo": "niri", - "type": "github" - } - }, "nix-github-actions": { "inputs": { "nixpkgs": [ @@ -467,11 +387,11 @@ }, "nixos-hardware": { "locked": { - "lastModified": 1742217307, - "narHash": "sha256-3fwpN7KN226ghLlpO9TR0/WpgQOmOj1e8bieUxpIYSk=", + "lastModified": 1742180333, + "narHash": "sha256-SrvP0G0fxz35lvQxBhAeJOl6+BueIsxJ4azMX+l/kAU=", "owner": "NixOS", "repo": "nixos-hardware", - "rev": "4f4d97d7b7be387286cc9c988760a7ebaa5be1f1", + "rev": "113cd3916682def185290145924fa30b30bda972", "type": "github" }, "original": { @@ -483,11 +403,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1742268799, - "narHash": "sha256-IhnK4LhkBlf14/F8THvUy3xi/TxSQkp9hikfDZRD4Ic=", + "lastModified": 1742136038, + "narHash": "sha256-DDe16FJk18sadknQKKG/9FbwEro7A57tg9vB5kxZ8kY=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "da044451c6a70518db5b730fe277b70f494188f1", + "rev": "a1185f4064c18a5db37c5c84e5638c78b46e3341", "type": "github" }, "original": { @@ -525,22 +445,6 @@ "type": "github" } }, - "nixpkgs-stable_2": { - "locked": { - "lastModified": 1742268799, - "narHash": "sha256-IhnK4LhkBlf14/F8THvUy3xi/TxSQkp9hikfDZRD4Ic=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "da044451c6a70518db5b730fe277b70f494188f1", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-24.11", - "repo": "nixpkgs", - "type": "github" - } - }, "nixpkgs-unstable": { "locked": { "lastModified": 1742069588, @@ -619,12 +523,10 @@ "inputs": { "authentik-nix": "authentik-nix", "flake-utils": "flake-utils_2", - "home-manager": "home-manager", "lanzaboote": "lanzaboote", "lix": "lix", "lix-module": "lix-module", "microvm": "microvm", - "niri": "niri", "nixos-hardware": "nixos-hardware", "nixpkgs": "nixpkgs", "nixpkgs-unstable": "nixpkgs-unstable", @@ -665,11 +567,11 @@ ] }, "locked": { - "lastModified": 1742239755, - "narHash": "sha256-ptn8dR4Uat3UUadGYNnB7CIH9SQm8mK69D2A/twBUXQ=", + "lastModified": 1742206174, + "narHash": "sha256-Fwo/KZl8+OLvm/XcA/6cSvoG2XxHrKNITR08S78pGus=", "owner": "Mic92", "repo": "sops-nix", - "rev": "787afce414bcce803b605c510b60bf43c11f4b55", + "rev": "c00da36830ae93f200b4a10eae0a56b733616774", "type": "github" }, "original": { @@ -815,39 +717,6 @@ "type": "git", "url": "https://git.oxapentane.com/0xa/website.git" } - }, - "xwayland-satellite-stable": { - "flake": false, - "locked": { - "lastModified": 1739246919, - "narHash": "sha256-/hBM43/Gd0/tW+egrhlWgOIISeJxEs2uAOIYVpfDKeU=", - "owner": "Supreeeme", - "repo": "xwayland-satellite", - "rev": "44590a416d4a3e8220e19e29e0b6efe64a80315d", - "type": "github" - }, - "original": { - "owner": "Supreeeme", - "ref": "v0.5.1", - "repo": "xwayland-satellite", - "type": "github" - } - }, - "xwayland-satellite-unstable": { - "flake": false, - "locked": { - "lastModified": 1742249030, - "narHash": "sha256-YZ+axsuNsgIKWfnRkt6Qa9UoKfUOIWf42vNUonXxmxM=", - "owner": "Supreeeme", - "repo": "xwayland-satellite", - "rev": "cca74a5f6b23742d77dc5db4312dfc40fd4a0fcc", - "type": "github" - }, - "original": { - "owner": "Supreeeme", - "repo": "xwayland-satellite", - "type": "github" - } } }, "root": "root", diff --git a/flake.nix b/flake.nix index 1dca929..9a59f52 100644 --- a/flake.nix +++ b/flake.nix @@ -47,16 +47,6 @@ inputs.flake-utils.follows = "flake-utils"; }; - home-manager = { - url = "github:nix-community/home-manager/release-24.11"; - inputs.nixpkgs.follows = "nixpkgs"; - }; - - niri = { - url = "github:sodiboo/niri-flake/main"; - inputs.nixpkgs.follows = "nixpkgs"; - }; - tmux-yank = { url = "github:tmux-plugins/tmux-yank"; flake = false; @@ -66,11 +56,9 @@ outputs = inputs@{ authentik-nix, - home-manager, lanzaboote, lix-module, microvm, - niri, nixos-hardware, nixpkgs, sops-nix, @@ -117,20 +105,13 @@ lanzaboote.nixosModules.lanzaboote nixos-hardware.nixosModules.lenovo-thinkpad-t14-amd-gen3 lix-module.nixosModules.default - home-manager.nixosModules.home-manager - niri.nixosModules.niri - { - home-manager.useGlobalPkgs = true; - home-manager.useUserPackages = true; - home-manager.users."0xa" = import ./hosts/toaster/0xa-home.nix; - } ./hosts/toaster ./modules/basic-tools ./modules/binary-caches.nix ./modules/devtools.nix - ./modules/niri.nix + ./modules/gnome.nix ./modules/gnupg.nix ./modules/radio.nix ./modules/science.nix diff --git a/hosts/toaster/0xa-home.nix b/hosts/toaster/0xa-home.nix deleted file mode 100644 index b3ff5eb..0000000 --- a/hosts/toaster/0xa-home.nix +++ /dev/null @@ -1,21 +0,0 @@ -{ pkgs, ... }: -{ - home.stateVersion = "24.11"; - - home.pointerCursor = { - name = "Banana"; - size = 32; - package = pkgs.banana-cursor; - x11.enable = true; - gtk.enable = true; - }; - - gtk = { - enable = true; - cursorTheme = { - name = "Banana"; - size = 32; - package = pkgs.banana-cursor; - }; - }; -} diff --git a/hosts/toaster/network/default.nix b/hosts/toaster/network/default.nix index ee0bdbe..6d96c3c 100644 --- a/hosts/toaster/network/default.nix +++ b/hosts/toaster/network/default.nix @@ -1,4 +1,4 @@ -{ lib, pkgs, ... }: +{ lib, config, ... }: { imports = [ ./mullvad.nix @@ -6,21 +6,26 @@ ./zw.nix ]; - environment.systemPackages = with pkgs; [ - iwgtk - impala - ]; + # Networkmanager shouldn't interfere with systemd managed interfaces + networking.networkmanager.unmanaged = + let + systemd_netdevs = lib.attrsets.attrValues ( + lib.attrsets.mapAttrs (_name: value: value.netdevConfig.Name) config.systemd.network.netdevs + ); + in + systemd_netdevs; - # kick out networkmanager - networking.networkmanager.enable = lib.mkForce false; - networking.useNetworkd = true; - systemd.network.enable = true; + systemd.network = { + enable = true; + wait-online.enable = false; # uplink is managed by networkmanager + }; + + users.users."0xa".extraGroups = [ "networkmanager" ]; networking = { hostName = "toaster"; firewall.enable = true; wireguard.enable = true; - wireless.iwd.enable = true; }; services.resolved = { @@ -34,38 +39,4 @@ ]; }; - # we might have no interwebs at all - systemd.network.wait-online.enable = false; - - # uplinks - systemd.network.networks = { - "10-ether-uplink" = { - matchConfig.Name = "enp1s0f0"; - networkConfig = { - DHCP = "yes"; - IPv6AcceptRA = true; - }; - }; - "10-dock-uplink" = { - matchConfig.Name = "enp5s0f4u1u1"; - networkConfig = { - DHCP = "yes"; - IPv6AcceptRA = true; - }; - dhcpV4Config = { - RouteMetric = 666; - }; - dhcpV6Config = { - RouteMetric = 666; - }; - }; - "wlan-uplink" = { - matchConfig.Name = "wlan0"; - networkConfig = { - DHCP = "yes"; - IPv6AcceptRA = true; - }; - }; - }; - } diff --git a/modules/niri.nix b/modules/sway.nix similarity index 69% rename from modules/niri.nix rename to modules/sway.nix index 1a8b59d..47f5698 100644 --- a/modules/niri.nix +++ b/modules/sway.nix @@ -4,10 +4,6 @@ let unstablepkgs = inputs.nixpkgs-unstable.legacyPackages.${pkgs.system}; in { - nixpkgs.overlays = [ inputs.niri.overlays.niri ]; - - programs.niri.enable = true; - imports = [ ./desktop-software.nix ./fonts.nix @@ -17,6 +13,7 @@ in qbittorrent gajim imv + swayimg mpv evince brightnessctl @@ -31,25 +28,6 @@ in spotify-player zathura ncdu - adwaita-icon-theme - bluetui - gammastep - graphicsmagick - unstablepkgs.i3status-rust - impala - kanshi - pamixer - swayidle - swaylock - wl-clipboard - xfce.thunar - banana-cursor - fuzzel - alacritty - unstablepkgs.i3bar-river - mako - swww - oculante ]; # Enable sound. @@ -74,16 +52,45 @@ in programs.light.enable = true; programs.xwayland.enable = true; - - programs.hyprland.enable = true; - + programs.sway = { + enable = true; + wrapperFeatures.gtk = true; + extraSessionCommands = '' + export SDL_VIDEODRIVER=wayland + export QT_QPA_PLATFORM=wayland-egl + export QT_WAYLAND_DISABLE_WINDOWDECORATION="1" + export QT_QPA_PLATFORMTHEME="gnome" + export QT_STYLE_OVERRIDE="adwaita-dark" + # export WLR_DRM_NO_ATOMIC=1 + ''; + extraPackages = with pkgs; [ + adwaita-icon-theme + bluetui + foot + gammastep + graphicsmagick + grim + unstablepkgs.i3status-rust + impala + kanshi + swaynotificationcenter + pamixer + rofi-wayland + slurp + swayidle + swaylock + wl-clipboard + wl-mirror + xfce.thunar + ]; + }; environment.sessionVariables = { GTK_THEME = "Adwaita:dark"; }; xdg.portal = { enable = true; wlr.enable = true; - extraPortals = [ pkgs.xdg-desktop-portal-gnome ]; + extraPortals = [ pkgs.xdg-desktop-portal-gtk ]; }; services.udisks2.enable = true; @@ -111,7 +118,7 @@ in enable = true; settings = { default_session = { - command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --greeting \"$(${pkgs.fortune}/bin/fortune -s)\" --cmd ${pkgs.niri-stable}/bin/niri-session"; + command = "${pkgs.greetd.tuigreet}/bin/tuigreet --time --greeting \"$(${pkgs.fortune}/bin/fortune -s)\" --cmd ${pkgs.sway}/bin/sway"; }; }; };