add fs & state version & fixes
This commit is contained in:
parent
b153246f90
commit
662d5a9f2e
4 changed files with 26 additions and 14 deletions
|
@ -46,7 +46,7 @@
|
||||||
nixosConfigurations = builtins.mapAttrs (name: config:
|
nixosConfigurations = builtins.mapAttrs (name: config:
|
||||||
(getNixpkgs config.ver).lib.nixosSystem {
|
(getNixpkgs config.ver).lib.nixosSystem {
|
||||||
system = config.system;
|
system = config.system;
|
||||||
modules = config.modules ++ defaultModules ++ [{ hostName = ${name}; }];
|
modules = config.modules ++ defaultModules ++ [{ hostName = "${name}"; }];
|
||||||
}
|
}
|
||||||
) nodes;
|
) nodes;
|
||||||
|
|
||||||
|
@ -56,7 +56,6 @@
|
||||||
magicRollback = true;
|
magicRollback = true;
|
||||||
remoteBuild = true;
|
remoteBuild = true;
|
||||||
nodes = builtins.mapAttrs (name: config: {
|
nodes = builtins.mapAttrs (name: config: {
|
||||||
"${name}" = {
|
|
||||||
hostname = builtins.head (builtins.split "/" config.ip4);
|
hostname = builtins.head (builtins.split "/" config.ip4);
|
||||||
profilesOrder = [ "system" ];
|
profilesOrder = [ "system" ];
|
||||||
profiles = {
|
profiles = {
|
||||||
|
@ -64,7 +63,6 @@
|
||||||
path = (getDeployPkgs config.ver).deploy-rs.lib.activate.nixos self.nixosConfigurations.${name};
|
path = (getDeployPkgs config.ver).deploy-rs.lib.activate.nixos self.nixosConfigurations.${name};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
|
||||||
}) nodes;
|
}) nodes;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{
|
{
|
||||||
"bastion.mtz.lasuite.federez" = {
|
bastion-mtz-lasuite-federez = {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
ver = "25.05";
|
ver = "25.05";
|
||||||
modules = [
|
modules = [
|
||||||
|
@ -7,9 +7,14 @@
|
||||||
];
|
];
|
||||||
|
|
||||||
ip4 = "193.48.225.150/24";
|
ip4 = "193.48.225.150/24";
|
||||||
gIp4 = "193.48.225.254/24";
|
gIp4 = "193.48.225.254";
|
||||||
|
|
||||||
dev = "ens18";
|
dev = "ens18";
|
||||||
|
|
||||||
grubDevice = "/dev/sda";
|
grubDevice = "/dev/sda";
|
||||||
|
fileSystems."/" = {
|
||||||
|
device = "/dev/disk/by-uuid/04722f8d-5368-484b-8ec1-1dc10aad1b4a";
|
||||||
|
fsType = "ext4";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
{ pkgs, ... }:
|
{ pkgs, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
options.hostName = lib.mkOption {
|
options.hostName = lib.mkOption {
|
||||||
|
@ -8,8 +8,6 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
config = {
|
config = {
|
||||||
hostName = "awendap";
|
|
||||||
|
|
||||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||||
|
|
||||||
# Global packages
|
# Global packages
|
||||||
|
@ -25,5 +23,7 @@
|
||||||
curl
|
curl
|
||||||
wget
|
wget
|
||||||
];
|
];
|
||||||
|
|
||||||
|
system.stateVersion = "25.05";
|
||||||
};
|
};
|
||||||
}
|
}
|
|
@ -1,4 +1,4 @@
|
||||||
{ ... }:
|
{ config, lib, modulesPath, ... }:
|
||||||
|
|
||||||
let
|
let
|
||||||
# Import nodes
|
# Import nodes
|
||||||
|
@ -6,6 +6,15 @@ let
|
||||||
myNode = nodes."${config.hostName}";
|
myNode = nodes."${config.hostName}";
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
imports = [
|
||||||
|
(modulesPath + "/profiles/qemu-guest.nix")
|
||||||
|
];
|
||||||
|
|
||||||
|
fileSystems = myNode.fileSystems;
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ];
|
||||||
boot.loader.grub.enable = true;
|
boot.loader.grub.enable = true;
|
||||||
boot.loader.grub.device = myNode.grubDevice;
|
boot.loader.grub.device = myNode.grubDevice;
|
||||||
|
|
||||||
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
}
|
}
|
Loading…
Add table
Add a link
Reference in a new issue