Rename variable holding machine infos
This commit is contained in:
parent
b227f1865f
commit
58b2763c92
3 changed files with 14 additions and 14 deletions
|
@ -88,7 +88,7 @@
|
|||
(
|
||||
{ pkgs, ... }: {
|
||||
config._module.args = {
|
||||
machineInfo = machine // {
|
||||
machine = machine // {
|
||||
name = hostname;
|
||||
config = (pkgs.callPackage config { });
|
||||
};
|
||||
|
@ -126,7 +126,7 @@
|
|||
(
|
||||
{ pkgs, ... }: {
|
||||
config._module.args = {
|
||||
machineInfo = machine // {
|
||||
machine = machine // {
|
||||
name = hostname;
|
||||
config = machineConfig;
|
||||
};
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ lib, machineInfo, ... }: {
|
||||
{ lib, machine, ... }: {
|
||||
imports = [
|
||||
./modules/custom-build-vm.nix
|
||||
./modules/custom-sops-nix.nix
|
||||
|
@ -28,7 +28,7 @@
|
|||
vmVariantWithBootLoader = vmConfig;
|
||||
};
|
||||
|
||||
users.myUsers = machineInfo.config.users;
|
||||
users.myUsers = machine.config.users;
|
||||
|
||||
home-manager = {
|
||||
useUserPackages = true;
|
||||
|
@ -37,7 +37,7 @@
|
|||
users =
|
||||
lib.attrsets.concatMapAttrs (username: user:
|
||||
let
|
||||
hostname = machineInfo.name;
|
||||
hostname = machine.name;
|
||||
getUserConfig = import ./utils/user-config.nix { inherit lib; };
|
||||
configPath = getUserConfig { inherit hostname username; };
|
||||
in
|
||||
|
@ -50,19 +50,19 @@
|
|||
} // args);
|
||||
}
|
||||
else {})
|
||||
machineInfo.config.users;
|
||||
machine.config.users;
|
||||
};
|
||||
|
||||
# Networking
|
||||
networking.hostName = machineInfo.name;
|
||||
networking.hostName = machine.name;
|
||||
|
||||
# Set time zone
|
||||
time.timeZone = machineInfo.config.timeZone;
|
||||
time.timeZone = machine.config.timeZone;
|
||||
|
||||
# Configure keyboard layout
|
||||
console.keyMap = machineInfo.config.keyMap;
|
||||
services.xserver.xkb.layout = machineInfo.config.keyboardLayout;
|
||||
console.keyMap = machine.config.keyMap;
|
||||
services.xserver.xkb.layout = machine.config.keyboardLayout;
|
||||
|
||||
i18n.extraLocaleSettings = machineInfo.config.localeSettings;
|
||||
i18n.extraLocaleSettings = machine.config.localeSettings;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
{ lib, machineInfo, ... }: {
|
||||
{ lib, machine, ... }: {
|
||||
config = {
|
||||
nixpkgs = {
|
||||
config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) (
|
||||
let
|
||||
names =
|
||||
(lib.optional machineInfo.config.xone "xow_dongle-firmware") ++
|
||||
(lib.optionals machineInfo.config.nvidia [
|
||||
(lib.optional machine.config.xone "xow_dongle-firmware") ++
|
||||
(lib.optionals machine.config.nvidia [
|
||||
"cuda_cccl"
|
||||
"cuda_cudart"
|
||||
"cuda_cuobjdump"
|
||||
|
|
Loading…
Reference in a new issue