Switch to flakes
This commit is contained in:
parent
ba885cb236
commit
5efe0fd5a5
9 changed files with 121 additions and 6 deletions
45
nixos/flake.nix
Normal file
45
nixos/flake.nix
Normal file
|
@ -0,0 +1,45 @@
|
|||
{
|
||||
description = "System configuration";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "nixpkgs/nixos-22.11";
|
||||
home-manager.url = "github:nix-community/home-manager/release-22.11";
|
||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
outputs = { nixpkgs, home-manager, ... }:
|
||||
let
|
||||
system = "x86_64-linux"; # Use flake tools?
|
||||
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
config = { allowUnfree = true; };
|
||||
};
|
||||
|
||||
lib = nixpkgs.lib;
|
||||
in {
|
||||
homeManagerConfigurations = {
|
||||
tdpeuter = home-manager.lib.homeManagerConfiguration {
|
||||
pkgs = nixpkgs.legacyPackages.${system};
|
||||
modules = [
|
||||
./users/tdpeuter/home.nix
|
||||
{
|
||||
home = {
|
||||
username = "tdpeuter";
|
||||
homeDirectory = "/home/tdpeuter";
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
nixosConfigurations = {
|
||||
Tibo-NixTest = lib.nixosSystem { # Use hostname
|
||||
inherit system;
|
||||
modules = [
|
||||
./system/configuration.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue