2024-01-08 07:49:51 +03:00
|
|
|
{
|
|
|
|
description = "koi nixos";
|
|
|
|
|
|
|
|
nixConfig = {
|
|
|
|
experimental-features = [ "nix-command" "flakes" ];
|
|
|
|
|
|
|
|
extra-substituters = [
|
|
|
|
"https://nix-community.cachix.org"
|
|
|
|
];
|
|
|
|
extra-trusted-public-keys = [
|
|
|
|
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
|
|
|
];
|
|
|
|
};
|
|
|
|
|
|
|
|
inputs = {
|
|
|
|
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
2024-03-15 13:18:18 +03:00
|
|
|
nixpkgs-stable.url = "github:NixOS/nixpkgs/nixos-23.11";
|
2024-05-16 19:05:17 +03:00
|
|
|
vscode-server.url = "github:nix-community/nixos-vscode-server";
|
2024-01-08 07:49:51 +03:00
|
|
|
|
|
|
|
agenix = {
|
|
|
|
url = "github:ryantm/agenix";
|
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
inputs.darwin.follows = "";
|
|
|
|
};
|
|
|
|
|
|
|
|
bootspec-secureboot = {
|
|
|
|
url = "github:vikanezrimaya/bootspec-secureboot";
|
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
|
|
|
|
|
|
|
home-manager = {
|
|
|
|
url = "github:nix-community/home-manager/master";
|
|
|
|
inputs.nixpkgs.follows = "nixpkgs";
|
|
|
|
};
|
2024-03-03 06:32:03 +03:00
|
|
|
|
|
|
|
nix-darwin.url = "github:LnL7/nix-darwin";
|
|
|
|
nix-darwin.inputs.nixpkgs.follows = "nixpkgs";
|
2024-04-23 13:42:17 +03:00
|
|
|
|
|
|
|
nix-index-database.url = "github:nix-community/nix-index-database";
|
|
|
|
nix-index-database.inputs.nixpkgs.follows = "nixpkgs";
|
2024-08-04 02:24:50 +03:00
|
|
|
|
|
|
|
desu-deploy.url = "github:teidesu/desu-deploy/a77b8e790324df51471cf40924acff9643972dfa";
|
|
|
|
desu-deploy.inputs.nixpkgs.follows = "nixpkgs";
|
2024-01-08 07:49:51 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
outputs =
|
|
|
|
inputs@{ self
|
|
|
|
, nixpkgs
|
2024-03-15 13:18:18 +03:00
|
|
|
, nixpkgs-stable
|
2024-01-08 07:49:51 +03:00
|
|
|
, vscode-server
|
|
|
|
, agenix
|
|
|
|
, bootspec-secureboot
|
|
|
|
, home-manager
|
2024-03-03 06:32:03 +03:00
|
|
|
, nix-darwin
|
2024-08-04 02:24:50 +03:00
|
|
|
, desu-deploy
|
2024-01-08 07:49:51 +03:00
|
|
|
, ...
|
|
|
|
}:
|
|
|
|
let
|
2024-06-06 17:22:13 +03:00
|
|
|
specialArgsCommon = {
|
2024-03-03 06:32:03 +03:00
|
|
|
inherit inputs;
|
|
|
|
abs = path: ./. + ("/" + path);
|
|
|
|
};
|
2024-06-06 17:22:13 +03:00
|
|
|
|
|
|
|
mkDarwinSystem = {
|
|
|
|
modules ? [],
|
|
|
|
specialArgs ? {},
|
|
|
|
}: let
|
|
|
|
specialArgsMerged = specialArgsCommon // specialArgs;
|
|
|
|
in nix-darwin.lib.darwinSystem {
|
|
|
|
modules = [
|
|
|
|
agenix.darwinModules.default
|
|
|
|
home-manager.darwinModules.home-manager
|
|
|
|
{ home-manager.extraSpecialArgs = specialArgsMerged; }
|
|
|
|
] ++ modules;
|
|
|
|
specialArgs = specialArgsMerged;
|
|
|
|
};
|
|
|
|
|
|
|
|
mkNixosSystem = {
|
|
|
|
system,
|
|
|
|
modules ? [],
|
|
|
|
specialArgs ? {}
|
|
|
|
}: let
|
|
|
|
specialArgsMerged = specialArgsCommon // specialArgs // {
|
|
|
|
pkgs-stable = import nixpkgs-stable {
|
|
|
|
system = "x86_64-linux";
|
|
|
|
config = { allowUnfree = true; };
|
|
|
|
};
|
|
|
|
};
|
|
|
|
in nixpkgs.lib.nixosSystem {
|
|
|
|
inherit system;
|
|
|
|
modules = [
|
|
|
|
agenix.nixosModules.default
|
|
|
|
home-manager.nixosModules.home-manager
|
|
|
|
{ home-manager.extraSpecialArgs = specialArgsMerged; }
|
|
|
|
] ++ modules;
|
|
|
|
specialArgs = specialArgsMerged;
|
|
|
|
};
|
2024-01-08 07:49:51 +03:00
|
|
|
in
|
|
|
|
{
|
|
|
|
nixosConfigurations = {
|
2024-08-04 02:24:50 +03:00
|
|
|
koi = mkNixosSystem rec {
|
2024-01-08 07:49:51 +03:00
|
|
|
system = "x86_64-linux";
|
|
|
|
modules = [
|
|
|
|
bootspec-secureboot.nixosModules.bootspec-secureboot
|
2024-08-04 02:24:50 +03:00
|
|
|
desu-deploy.nixosModules.${system}.default
|
2024-01-08 07:49:51 +03:00
|
|
|
./hosts/koi/configuration.nix
|
|
|
|
];
|
2024-03-03 06:32:03 +03:00
|
|
|
};
|
2024-06-07 11:34:06 +03:00
|
|
|
|
|
|
|
homura = mkNixosSystem {
|
|
|
|
system = "x86_64-linux";
|
|
|
|
modules = [
|
|
|
|
./hosts/madohomu/homura.nix
|
|
|
|
];
|
|
|
|
};
|
|
|
|
|
|
|
|
madoka = mkNixosSystem {
|
|
|
|
system = "x86_64-linux";
|
|
|
|
modules = [
|
|
|
|
./hosts/madohomu/madoka.nix
|
|
|
|
];
|
|
|
|
};
|
2024-03-03 06:32:03 +03:00
|
|
|
};
|
|
|
|
|
|
|
|
darwinConfigurations = {
|
2024-06-06 17:22:13 +03:00
|
|
|
teidesu-osx = mkDarwinSystem {
|
2024-03-03 06:32:03 +03:00
|
|
|
modules = [
|
|
|
|
./hosts/teidesu-osx/configuration.nix
|
|
|
|
];
|
2024-01-08 07:49:51 +03:00
|
|
|
};
|
2024-05-01 06:02:01 +03:00
|
|
|
|
2024-06-06 17:22:13 +03:00
|
|
|
airi = mkDarwinSystem {
|
2024-05-01 06:02:01 +03:00
|
|
|
modules = [
|
|
|
|
./hosts/airi/configuration.nix
|
|
|
|
];
|
|
|
|
};
|
2024-01-08 07:49:51 +03:00
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|