mirror of
https://github.com/buckley310/nixos-config.git
synced 2024-12-21 19:24:15 +00:00
factor out hostnames
This commit is contained in:
parent
004d2b1263
commit
6f3ab9c4bf
6 changed files with 14 additions and 23 deletions
|
@ -1,9 +1,5 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
networking.hostName = "cube";
|
|
||||||
|
|
||||||
# imports = [ ./monitors.nix ];
|
|
||||||
|
|
||||||
virtualisation.libvirtd.enable = true;
|
virtualisation.libvirtd.enable = true;
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
virt-manager
|
virt-manager
|
||||||
|
|
|
@ -1,17 +1,20 @@
|
||||||
nixpkgs: hardware: nixosModule:
|
nixpkgs: hardware: nixosModule:
|
||||||
with hardware;
|
with hardware;
|
||||||
|
|
||||||
let
|
builtins.mapAttrs
|
||||||
sys = system: mods: nixpkgs.lib.nixosSystem {
|
|
||||||
inherit system;
|
(name: { system, mods }: nixpkgs.lib.nixosSystem {
|
||||||
modules = [ nixosModule ] ++ mods;
|
inherit system;
|
||||||
};
|
modules = mods ++ [
|
||||||
|
nixosModule
|
||||||
|
{ networking.hostName = name; }
|
||||||
|
];
|
||||||
|
})
|
||||||
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
cube = sys "x86_64-linux" [ physical ./cube ];
|
cube = { system = "x86_64-linux"; mods = [ physical ./cube ]; };
|
||||||
hp = sys "x86_64-linux" [ physical ./hp ];
|
hp = { system = "x86_64-linux"; mods = [ physical ./hp ]; };
|
||||||
lenny = sys "x86_64-linux" [ physical ./lenny ];
|
lenny = { system = "x86_64-linux"; mods = [ physical ./lenny ]; };
|
||||||
nixdev = sys "x86_64-linux" [ qemu ./nixdev ];
|
nixdev = { system = "x86_64-linux"; mods = [ qemu ./nixdev ]; };
|
||||||
slate = sys "x86_64-linux" [ physical ./slate ];
|
slate = { system = "x86_64-linux"; mods = [ physical ./slate ]; };
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
networking.hostName = "hp";
|
|
||||||
|
|
||||||
services = {
|
services = {
|
||||||
openssh.enable = true;
|
openssh.enable = true;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
networking.hostName = "lenny";
|
|
||||||
|
|
||||||
services = {
|
services = {
|
||||||
openssh.enable = true;
|
openssh.enable = true;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }:
|
||||||
{
|
{
|
||||||
networking.hostName = "nixdev";
|
|
||||||
|
|
||||||
sconfig = {
|
sconfig = {
|
||||||
gnome = true;
|
gnome = true;
|
||||||
profile = "desktop";
|
profile = "desktop";
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
{ pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
{
|
{
|
||||||
networking.hostName = "slate";
|
|
||||||
|
|
||||||
sconfig = {
|
sconfig = {
|
||||||
profile = "desktop";
|
profile = "desktop";
|
||||||
gnome = true;
|
gnome = true;
|
||||||
|
|
Loading…
Reference in a new issue