diff --git a/flake.nix b/flake.nix index 93c25ed..70c3fd9 100644 --- a/flake.nix +++ b/flake.nix @@ -2,7 +2,7 @@ description = "System configuration"; inputs = { - flake-utils-plus.url = "github:AtaraxiaSjel/flake-utils-plus"; + flake-utils-plus.url = "github:gytis-ivaskevicius/flake-utils-plus/v1.4.0"; nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; nixpkgs-master.url = "github:nixos/nixpkgs/master"; nixpkgs-stable.url = "github:nixos/nixpkgs/nixos-23.05"; @@ -106,8 +106,8 @@ ]; customModules = builtins.listToAttrs (findModules ./modules); - nixosProfiles = builtins.listToAttrs (findModules ./profiles); - nixosRoles = import ./roles; + customProfiles = builtins.listToAttrs (findModules ./profiles); + customRoles = import ./roles; sharedPatches = patchesPath [ "ivpn.patch" @@ -115,7 +115,8 @@ "vaultwarden.patch" "webhooks.patch" ]; - channelsConfig = { allowUnfree = true; }; + sharedOverlays = [ flake-utils-plus.overlay ]; + channelsConfig = { allowUnfree = true; android_sdk.accept_license = true; }; channels.unstable.input = nixpkgs; channels.unstable.patches = patchesPath [ "zen-kernels.patch" "ydotoold.patch" ] ++ sharedPatches; channels.stable.input = inputs.nixpkgs-stable; @@ -123,13 +124,12 @@ hostDefaults.system = "x86_64-linux"; hostDefaults.channelName = "unstable"; + hostDefaults.modules = with nixpkgs.lib; __attrValues self.customModules; hosts = with nixpkgs.lib; let hostnames = builtins.attrNames (builtins.readDir ./machines); - mkHost = name: let + mkHost = name: { system = builtins.readFile (./machines + "/${name}/system"); - in { - inherit system; - modules = __attrValues self.customModules ++ [ + modules = [ (import (./machines + "/${name}")) { device = name; mainuser = "ataraxia"; } inputs.vscode-server.nixosModule @@ -179,6 +179,7 @@ packages = with pkgs; [ rebuild update-vscode upgrade upgrade-hyprland nixfmt nixpkgs-fmt statix vulnix deadnix git deploy-rs + fup-repl ]; }; ci = pkgs.mkShell { diff --git a/machines/AMD-Workstation/default.nix b/machines/AMD-Workstation/default.nix index cbb2bdd..8fd710b 100644 --- a/machines/AMD-Workstation/default.nix +++ b/machines/AMD-Workstation/default.nix @@ -2,19 +2,19 @@ imports = with inputs.self; [ ./boot.nix ./hardware-configuration.nix - nixosRoles.workstation + customRoles.workstation - # nixosProfiles.stable-diffusion - nixosProfiles.a2ln-server - nixosProfiles.act - nixosProfiles.attic - nixosProfiles.bluetooth - nixosProfiles.cassowary - nixosProfiles.emulators - nixosProfiles.hoyo - nixosProfiles.minecraft - nixosProfiles.sunshine - nixosProfiles.wine-games + # customProfiles.stable-diffusion + customProfiles.a2ln-server + customProfiles.act + customProfiles.attic + customProfiles.bluetooth + customProfiles.cassowary + customProfiles.emulators + customProfiles.hoyo + customProfiles.minecraft + customProfiles.sunshine + customProfiles.wine-games ]; virtualisation.libvirt.guests = { diff --git a/machines/Dell-Laptop/default.nix b/machines/Dell-Laptop/default.nix index a068341..4024e49 100644 --- a/machines/Dell-Laptop/default.nix +++ b/machines/Dell-Laptop/default.nix @@ -2,9 +2,9 @@ imports = with inputs.self; [ ./boot.nix ./hardware-configuration.nix - nixosRoles.desktop + customRoles.desktop - nixosProfiles.bluetooth + customProfiles.bluetooth ]; deviceSpecific.devInfo = { diff --git a/machines/Home-Hypervisor/default.nix b/machines/Home-Hypervisor/default.nix index 37cbddc..32d2bfc 100644 --- a/machines/Home-Hypervisor/default.nix +++ b/machines/Home-Hypervisor/default.nix @@ -6,45 +6,45 @@ in { ./hardware-configuration.nix ./virtualisation.nix ./disks.nix - nixosProfiles.hardened + customProfiles.hardened - nixosRoles.hypervisor - nixosProfiles.acme - # nixosProfiles.authentik - nixosProfiles.battery-historian - nixosProfiles.duplicacy - nixosProfiles.fail2ban - # nixosProfiles.firefox-syncserver - nixosProfiles.gitea - nixosProfiles.joplin-server - nixosProfiles.mailserver - nixosProfiles.nginx - nixosProfiles.roundcube - nixosProfiles.tinyproxy - nixosProfiles.vaultwarden - nixosProfiles.vscode-server + customRoles.hypervisor + customProfiles.acme + customProfiles.authentik + customProfiles.battery-historian + customProfiles.duplicacy + customProfiles.fail2ban + # customProfiles.firefox-syncserver + customProfiles.gitea + customProfiles.joplin-server + customProfiles.mailserver + customProfiles.nginx + customProfiles.roundcube + customProfiles.tinyproxy + customProfiles.vaultwarden + customProfiles.vscode-server - nixosProfiles.media-stack - # nixosProfiles.copyparty - nixosProfiles.seafile - # nixosProfiles.cocalc - # nixosProfiles.neko-browser - nixosProfiles.openbooks - nixosProfiles.webhooks + customProfiles.media-stack + # customProfiles.copyparty + customProfiles.seafile + # customProfiles.cocalc + # customProfiles.neko-browser + customProfiles.openbooks + customProfiles.webhooks - nixosProfiles.yandex-db - nixosProfiles.hoyolab - nixosProfiles.it-tools - nixosProfiles.homepage - nixosProfiles.matrix - nixosProfiles.atticd - nixosProfiles.attic - nixosProfiles.restic-server - nixosProfiles.outline - nixosProfiles.radicale - nixosProfiles.wiki + customProfiles.yandex-db + customProfiles.hoyolab + customProfiles.it-tools + customProfiles.homepage + customProfiles.matrix + customProfiles.atticd + customProfiles.attic + customProfiles.restic-server + customProfiles.outline + customProfiles.radicale + customProfiles.wiki - (import nixosProfiles.blocky { + (import customProfiles.blocky { inherit config; inherit (import ./dns-mapping.nix) dns-mapping; }) diff --git a/machines/NixOS-VM/default.nix b/machines/NixOS-VM/default.nix index c2ff294..283c0e8 100644 --- a/machines/NixOS-VM/default.nix +++ b/machines/NixOS-VM/default.nix @@ -1,10 +1,10 @@ { inputs, config, lib, pkgs, ... }: { imports = with inputs.self; [ ./hardware-configuration.nix - # nixosRoles.base + # customRoles.base customModules.devices - nixosProfiles.attic + customProfiles.attic ]; options = { diff --git a/machines/NixOS-VPS/default.nix b/machines/NixOS-VPS/default.nix index 8171c89..ad0a9fc 100644 --- a/machines/NixOS-VPS/default.nix +++ b/machines/NixOS-VPS/default.nix @@ -23,8 +23,8 @@ customModules.devices customModules.users - nixosProfiles.hardened - nixosProfiles.overlay + customProfiles.hardened + customProfiles.overlay ]; # disko.devices = import ./disko.nix { inherit lib; }; diff --git a/roles/base.nix b/roles/base.nix index 9003cd9..e65176b 100644 --- a/roles/base.nix +++ b/roles/base.nix @@ -1,5 +1,5 @@ { inputs, ... }: { - imports = with inputs.self.nixosProfiles; [ + imports = with inputs.self.customProfiles; [ inputs.home-manager.nixosModules.home-manager { home-manager.useGlobalPkgs = true; home-manager.useUserPackages = true; diff --git a/roles/container.nix b/roles/container.nix index 6b38a64..ecf71ae 100644 --- a/roles/container.nix +++ b/roles/container.nix @@ -1,5 +1,5 @@ { inputs, pkgs, ... }: { - imports = with inputs.self.nixosProfiles; [ + imports = with inputs.self.customProfiles; [ inputs.home-manager.nixosModules.home-manager { home-manager.useGlobalPkgs = true; home-manager.useUserPackages = true; diff --git a/roles/desktop.nix b/roles/desktop.nix index e60752b..630154d 100644 --- a/roles/desktop.nix +++ b/roles/desktop.nix @@ -1,8 +1,8 @@ { inputs, ... }: { - imports = with inputs.self.nixosProfiles; [ + imports = with inputs.self.customProfiles; [ ./base.nix inputs.base16.hmModule - inputs.self.nixosProfiles.seadrive + inputs.self.customProfiles.seadrive applications-setup hardware diff --git a/roles/hypervisor.nix b/roles/hypervisor.nix index 2ea7631..ff62160 100644 --- a/roles/hypervisor.nix +++ b/roles/hypervisor.nix @@ -1,5 +1,5 @@ { inputs, pkgs, ... }: { - imports = with inputs.self.nixosProfiles; [ + imports = with inputs.self.customProfiles; [ inputs.home-manager.nixosModules.home-manager { home-manager.useGlobalPkgs = true; home-manager.useUserPackages = true; diff --git a/roles/workstation.nix b/roles/workstation.nix index 7a718df..57b42a1 100644 --- a/roles/workstation.nix +++ b/roles/workstation.nix @@ -1,5 +1,5 @@ { inputs, ... }: { imports = with inputs.self; [ - nixosRoles.desktop + customRoles.desktop ]; }