Reviewed-on: https://codeberg.org/serenity-F/nixdots/pulls/5
Co-authored-by: Serenity-F <serenity-amalgam@protonmail.com>
Co-committed-by: Serenity-F <serenity-amalgam@protonmail.com>
This commit is contained in:
Serenity-F 2024-04-08 13:15:48 +00:00 • committed by Serenity
parent d80bb11377
commit c72fa779fc
33 changed files with 458 additions and 1361 deletions

View file

@ -1,61 +1,36 @@
{
description = "Serenity's NixOS configuration";
description = "SerenityOS v0.2.9";
inputs = {
# Nixpkgs and home mananger
nixpkgs.url = "nixpkgs/nixos-23.11";
nixpkgs-unstable.url = "nixpkgs/nixos-unstable";
home-manager.url = "github:nix-community/home-manager/release-23.11";
home-manager.inputs.nixpkgs.follows = "nixpkgs";
# Hardware specific configuration stuff
# Nixpkgs and hardware specific configs
# there was a way to have unstable as an overlay,
# will set it back up, lazy rn, for now pick one
# nixpkgs.url = "nixpkgs/nixos-23.11";
nixpkgs.url = "nixpkgs/nixos-unstable";
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
# Packages
# apoth-admin.url = "git+https://codeberg.org/Apothecary/apoth-admin.git";
# apoth-admin.inputs.nixpkgs.follows = "nixpkgs-unstable";
# declarative disks
disko = {
url = "github:nix-community/disko";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs =
{ nixpkgs
, nixpkgs-unstable
, home-manager
, nixos-hardware
# , apoth-admin
, ...
}:
let
system = "x86_64-linux";
overlay-unstable = final: prev: {
unstable = import nixpkgs-unstable {
inherit system;
config.allowUnfree = true;
};
};
home-manager-config = toplevel: [
home-manager.nixosModules.home-manager # Home manager go brrrr
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
# ASK AKESI ABOUT EASIER WAY TO LOAD ALL USERS MAYBE?
home-manager.users.serenity = toplevel;
# Optionally, use home-manager.extraSpecialArgs to pass
# arguments to home.nix
}
];
overlay-flake-pkgs = final: prev: {
};
common-modules = [
({ config, pkgs, ... }: { nixpkgs.overlays = [ overlay-unstable overlay-flake-pkgs ]; })
];
in
{
nixosConfigurations = {
proserpina = nixpkgs.lib.nixosSystem {
inherit system;
modules = [
./hosts/proserpina/configuration.nix # Load muir main nix config
# nixos-hardware.nixosModules.$MODEL
] ++ home-manager-config (import ./hosts/proserpina/home.nix) ++ common-modules;
};
outputs = { nixpkgs, nixos-hardware, disko, ... }: {
nixosConfigurations = {
proserpina = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [
# nixos-hardware.nixosModules.$MODEL
./hosts/proserpina/configuration.nix
disko.nixosModules.disko
];
};
};
};
}