2023-02-26 18:45:26 +01:00
|
|
|
{ config, pkgs, lib, ...}:
|
|
|
|
|
|
|
|
with lib;
|
|
|
|
|
2023-10-20 22:57:33 +02:00
|
|
|
{
|
2023-02-26 18:45:26 +01:00
|
|
|
options.clerie.nixfiles.enable = mkEnableOption "clerie nixfiles tools";
|
|
|
|
config = mkIf config.clerie.nixfiles.enable {
|
|
|
|
system.nixos-generate-config.configuration = ''
|
|
|
|
{ config, pkgs, lib, ... }:
|
|
|
|
|
|
|
|
{
|
|
|
|
imports =
|
|
|
|
[
|
|
|
|
./hardware-configuration.nix
|
|
|
|
];
|
|
|
|
|
|
|
|
$bootLoaderConfig
|
|
|
|
|
|
|
|
networking.hostName = "%HOSTNAME%";
|
|
|
|
|
|
|
|
clerie.monitoring = {
|
|
|
|
# enable = true;
|
|
|
|
id = "%MONITORING_ID%";
|
|
|
|
pubkey = "%MONITORING_PUBKEY%";
|
|
|
|
};
|
|
|
|
|
|
|
|
system.stateVersion = "${config.system.nixos.release}";
|
|
|
|
}
|
|
|
|
'';
|
|
|
|
|
2023-10-20 22:57:33 +02:00
|
|
|
environment.systemPackages = with pkgs; [
|
2023-02-26 18:45:26 +01:00
|
|
|
nixfiles-generate-config
|
|
|
|
];
|
|
|
|
};
|
|
|
|
}
|