kacper inspirerat
This commit is contained in:
@@ -2,6 +2,8 @@
|
||||
description = "NixOS configuration";
|
||||
|
||||
inputs = {
|
||||
flake-parts.url = "github:hercules-ci/flake-parts";
|
||||
|
||||
nixpkgs-stable.url = "github:NixOS/nixpkgs/nixos-25.05";
|
||||
nixpkgs-unstable.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
|
||||
@@ -40,83 +42,10 @@
|
||||
};
|
||||
};
|
||||
|
||||
outputs =
|
||||
inputs@{
|
||||
nixpkgs-stable,
|
||||
nixpkgs-unstable,
|
||||
disko-stable,
|
||||
disko-unstable,
|
||||
home-manager-unstable,
|
||||
dotfiles,
|
||||
...
|
||||
}:
|
||||
let
|
||||
mkHost = {
|
||||
hostPath,
|
||||
nixpkgs,
|
||||
disko,
|
||||
lolcat,
|
||||
}:
|
||||
nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {
|
||||
inputs = inputs // { "lolcat++" = lolcat; };
|
||||
};
|
||||
modules = [
|
||||
disko.nixosModules.disko
|
||||
hostPath
|
||||
];
|
||||
};
|
||||
mkDesktopHost = {
|
||||
hostPath,
|
||||
nixpkgs,
|
||||
disko,
|
||||
lolcat,
|
||||
}:
|
||||
nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {
|
||||
inputs = inputs // { "lolcat++" = lolcat; };
|
||||
};
|
||||
modules = [
|
||||
disko.nixosModules.disko
|
||||
home-manager-unstable.nixosModules.home-manager
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.backupFileExtension = "hm-backup";
|
||||
home-manager.users.love = import "${dotfiles}/home.nix";
|
||||
}
|
||||
hostPath
|
||||
];
|
||||
};
|
||||
in
|
||||
{
|
||||
nixosConfigurations = {
|
||||
Kronos = mkDesktopHost {
|
||||
hostPath = ./hosts/kronos;
|
||||
nixpkgs = nixpkgs-unstable;
|
||||
disko = disko-unstable;
|
||||
lolcat = inputs."lolcat++-unstable";
|
||||
};
|
||||
kronos = mkDesktopHost {
|
||||
hostPath = ./hosts/kronos;
|
||||
nixpkgs = nixpkgs-unstable;
|
||||
disko = disko-unstable;
|
||||
lolcat = inputs."lolcat++-unstable";
|
||||
};
|
||||
Hermes = mkHost {
|
||||
hostPath = ./hosts/hermes;
|
||||
nixpkgs = nixpkgs-stable;
|
||||
disko = disko-stable;
|
||||
lolcat = inputs."lolcat++-stable";
|
||||
};
|
||||
hermes = mkHost {
|
||||
hostPath = ./hosts/hermes;
|
||||
nixpkgs = nixpkgs-stable;
|
||||
disko = disko-stable;
|
||||
lolcat = inputs."lolcat++-stable";
|
||||
};
|
||||
};
|
||||
outputs = inputs:
|
||||
inputs.flake-parts.lib.mkFlake { inherit inputs; } {
|
||||
imports = [
|
||||
./modules/flake/parts.nix
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
{
|
||||
inputs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
inherit (inputs) dotfiles home-manager-unstable;
|
||||
in
|
||||
{
|
||||
mkHost = {
|
||||
nixpkgs,
|
||||
disko,
|
||||
lolcat,
|
||||
modules ? [ ],
|
||||
}:
|
||||
nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {
|
||||
inputs = inputs // { "lolcat++" = lolcat; };
|
||||
};
|
||||
modules = [ disko.nixosModules.disko ] ++ modules;
|
||||
};
|
||||
|
||||
mkDesktopHost = {
|
||||
nixpkgs,
|
||||
disko,
|
||||
lolcat,
|
||||
modules ? [ ],
|
||||
}:
|
||||
nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = {
|
||||
inputs = inputs // { "lolcat++" = lolcat; };
|
||||
};
|
||||
modules = [
|
||||
disko.nixosModules.disko
|
||||
home-manager-unstable.nixosModules.home-manager
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.backupFileExtension = "hm-backup";
|
||||
home-manager.users.love = import "${dotfiles}/home.nix";
|
||||
}
|
||||
] ++ modules;
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{ inputs }:
|
||||
let
|
||||
modules = import ../nixos;
|
||||
flakeLib = import ./lib.nix { inherit inputs; };
|
||||
in
|
||||
import ../hosts ({ inherit inputs modules; } // flakeLib)
|
||||
@@ -0,0 +1,9 @@
|
||||
{ inputs, ... }:
|
||||
{
|
||||
systems = [ "x86_64-linux" ];
|
||||
|
||||
flake = {
|
||||
nixosModules = import ../nixos;
|
||||
nixosConfigurations = import ./nixos-configurations.nix { inherit inputs; };
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
args:
|
||||
(import ./hermes args) // (import ./kronos args)
|
||||
@@ -2,6 +2,7 @@
|
||||
inputs,
|
||||
config,
|
||||
pkgs,
|
||||
modules,
|
||||
...
|
||||
}:
|
||||
let
|
||||
@@ -24,14 +25,12 @@ in
|
||||
|
||||
imports = [
|
||||
inputs.mailserver.nixosModules.default
|
||||
./hardware-configuration.nix
|
||||
./disko.nix
|
||||
./mail.nix
|
||||
./roundcube.nix
|
||||
../../modules/base.nix
|
||||
../../modules/zfs-root.nix
|
||||
../../modules/desktop-hyprland.nix
|
||||
../../modules/bin-bash-wrapper.nix
|
||||
modules.base
|
||||
modules.zfsRoot
|
||||
modules.desktopHyprland
|
||||
modules.mailServer
|
||||
modules.binBashWrapper
|
||||
];
|
||||
|
||||
my.binBashWrapper.enable = true;
|
||||
@@ -0,0 +1,20 @@
|
||||
{
|
||||
inputs,
|
||||
mkHost,
|
||||
...
|
||||
}:
|
||||
{
|
||||
Hermes = mkHost {
|
||||
nixpkgs = inputs.nixpkgs-stable;
|
||||
disko = inputs.disko-stable;
|
||||
lolcat = inputs."lolcat++-stable";
|
||||
modules = [ ./configuration.nix ];
|
||||
};
|
||||
|
||||
hermes = mkHost {
|
||||
nixpkgs = inputs.nixpkgs-stable;
|
||||
disko = inputs.disko-stable;
|
||||
lolcat = inputs."lolcat++-stable";
|
||||
modules = [ ./configuration.nix ];
|
||||
};
|
||||
}
|
||||
@@ -1,6 +1,7 @@
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
modules,
|
||||
...
|
||||
}:
|
||||
let
|
||||
@@ -22,12 +23,12 @@ in
|
||||
};
|
||||
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./hardware.nix
|
||||
./disko.nix
|
||||
../../modules/base.nix
|
||||
../../modules/zfs-root.nix
|
||||
../../modules/desktop-hyprland.nix
|
||||
../../modules/bin-bash-wrapper.nix
|
||||
modules.base
|
||||
modules.zfsRoot
|
||||
modules.desktopHyprland
|
||||
modules.binBashWrapper
|
||||
];
|
||||
|
||||
my.binBashWrapper.enable = true;
|
||||
@@ -0,0 +1,20 @@
|
||||
{
|
||||
inputs,
|
||||
mkDesktopHost,
|
||||
...
|
||||
}:
|
||||
{
|
||||
Kronos = mkDesktopHost {
|
||||
nixpkgs = inputs.nixpkgs-unstable;
|
||||
disko = inputs.disko-unstable;
|
||||
lolcat = inputs."lolcat++-unstable";
|
||||
modules = [ ./configuration.nix ];
|
||||
};
|
||||
|
||||
kronos = mkDesktopHost {
|
||||
nixpkgs = inputs.nixpkgs-unstable;
|
||||
disko = inputs.disko-unstable;
|
||||
lolcat = inputs."lolcat++-unstable";
|
||||
modules = [ ./configuration.nix ];
|
||||
};
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
{
|
||||
base = import ./base.nix;
|
||||
binBashWrapper = import ./bin-bash-wrapper.nix;
|
||||
desktopHyprland = import ./desktop-hyprland.nix;
|
||||
mailServer = import ./mail-server;
|
||||
zfsRoot = import ./zfs-root.nix;
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
{
|
||||
imports = [
|
||||
./mail.nix
|
||||
./roundcube.nix
|
||||
];
|
||||
}
|
||||
@@ -16,7 +16,7 @@
|
||||
# nix-shell -p mkpasswd --run 'mkpasswd -s'
|
||||
accounts = {
|
||||
"love@billenius.com" = {
|
||||
hashedPasswordFile = ./mail-password-hash/love@billenius.com;
|
||||
hashedPasswordFile = ../../../resources/mail-server/love@billenius.com;
|
||||
aliases = [ "postmaster@billenius.com" ];
|
||||
};
|
||||
};
|
||||
Reference in New Issue
Block a user