Compare commits
No commits in common. "d613dee36414595ce3f49c72a0d546d086a7e027" and "0e5ebb37f1ce8f93dd7316156567094f1aba788b" have entirely different histories.
d613dee364
...
0e5ebb37f1
3 changed files with 29 additions and 9 deletions
10
flake.nix
10
flake.nix
|
|
@ -91,9 +91,15 @@
|
|||
util = import ./util {inherit inputs;};
|
||||
forEachPkgs = util.forEachPkgs;
|
||||
|
||||
mkNixosInstaller = util.mkNixosInstaller;
|
||||
mkNixosSystem = util.mkNixosSystem;
|
||||
mkDarwinSystem = util.mkDarwinSystem;
|
||||
mkHome = util.mkHome;
|
||||
syncthingConfiguration = util.syncthingConfiguration;
|
||||
|
||||
installerSystems = {
|
||||
basic = mkNixosInstaller "basic" [];
|
||||
};
|
||||
|
||||
nixosSystems = {
|
||||
horizon = mkNixosSystem "horizon";
|
||||
|
|
@ -164,10 +170,14 @@
|
|||
};
|
||||
});
|
||||
|
||||
installerConfigurations = installerSystems;
|
||||
|
||||
nixosConfigurations = nixosSystems;
|
||||
|
||||
darwinConfigurations = darwinSystems;
|
||||
|
||||
homeConfigurations = homeConfigurations;
|
||||
|
||||
syncthingConfiguration = syncthingConfiguration;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
syncthingConfiguration,
|
||||
outputs,
|
||||
...
|
||||
}: let
|
||||
mountDir = "/mnt/sync";
|
||||
|
|
@ -27,7 +27,7 @@ in {
|
|||
configDir = configDir;
|
||||
overrideDevices = true;
|
||||
overrideFolders = true;
|
||||
configuration = syncthingConfiguration;
|
||||
configuration = outputs.syncthingConfiguration;
|
||||
deviceName = config.networking.hostName;
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -52,12 +52,6 @@
|
|||
home-manager-config
|
||||
../modules/system-modules
|
||||
];
|
||||
|
||||
syncthingConfiguration = nix-syncthing.lib.syncthingConfiguration {
|
||||
modules = [
|
||||
(import ../configurations/syncthing)
|
||||
];
|
||||
};
|
||||
in {
|
||||
forEachPkgs = lambda: forEachSystem (system: lambda system (pkgsFor system));
|
||||
|
||||
|
|
@ -68,9 +62,19 @@ in {
|
|||
(lib.mkUnless condition no)
|
||||
];
|
||||
|
||||
mkNixosInstaller = host: userKeys:
|
||||
nixpkgs.lib.nixosSystem {
|
||||
modules = [
|
||||
{
|
||||
# TODO: authorized keys for all users and hosts
|
||||
}
|
||||
../configurations/nixos/${host}
|
||||
];
|
||||
};
|
||||
|
||||
mkNixosSystem = host:
|
||||
nixpkgs.lib.nixosSystem {
|
||||
specialArgs = {inherit inputs outputs util syncthingConfiguration;};
|
||||
specialArgs = {inherit inputs outputs util;};
|
||||
modules =
|
||||
system-modules
|
||||
++ [
|
||||
|
|
@ -115,4 +119,10 @@ in {
|
|||
../configurations/home-manager/${user}
|
||||
];
|
||||
};
|
||||
|
||||
syncthingConfiguration = nix-syncthing.lib.syncthingConfiguration {
|
||||
modules = [
|
||||
(import ../configurations/syncthing)
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue