set hostname toplevel

This commit is contained in:
Vivian 2022-07-30 22:57:42 +02:00
parent 1f937300ff
commit 378e3831e4
17 changed files with 5 additions and 32 deletions

View file

@ -53,9 +53,13 @@
}; };
}; };
mkColmenaHost = { ip, hostname, tags, ... }@host: { mkColmenaHost = { ip, hostname, tags, location, ... }@host: {
"${hostname}" = { "${hostname}" = {
imports = resolveImports host; imports = resolveImports host;
networking = {
hostName = hostname;
domain = location;
};
deployment = { deployment = {
inherit tags; inherit tags;
targetHost = ip; targetHost = ip;

View file

@ -28,8 +28,6 @@ in {
boot.loader.grub.version = 2; boot.loader.grub.version = 2;
boot.loader.grub.device = "/dev/sda"; boot.loader.grub.device = "/dev/sda";
networking.hostName = "bastion";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -9,8 +9,6 @@ in
{ {
imports = [ ]; imports = [ ];
networking.hostName = "database";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -10,7 +10,6 @@ in {
imports = [ ]; imports = [ ];
networking = { networking = {
hostName = "dhcp";
defaultGateway = "10.42.42.1"; defaultGateway = "10.42.42.1";
nameservers = [ "10.42.42.15" "10.42.42.16" ]; nameservers = [ "10.42.42.15" "10.42.42.16" ];
interfaces.eth0 = { interfaces.eth0 = {

View file

@ -13,8 +13,6 @@ let
in { in {
imports = [ ]; imports = [ ];
networking.hostName = "dns";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -6,8 +6,6 @@
{ {
imports = [ ]; imports = [ ];
networking.hostName = "gitea";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -11,8 +11,6 @@ in
{ {
imports = [ ]; imports = [ ];
networking.hostName = "hedgedoc";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -14,8 +14,6 @@
boot.kernel.sysctl."fs.inotify.max_user_instances" = 2147483647; # INT_MAX, dynamically limited based on available memory boot.kernel.sysctl."fs.inotify.max_user_instances" = 2147483647; # INT_MAX, dynamically limited based on available memory
boot.kernel.sysctl."fs.inotify.max_user_watches" = 1048576; boot.kernel.sysctl."fs.inotify.max_user_watches" = 1048576;
networking.hostName = "k3s-node1";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -6,8 +6,6 @@
{ {
imports = [ ]; imports = [ ];
networking.hostName = "minecraft";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -10,8 +10,6 @@ let
in { in {
imports = [ ]; imports = [ ];
networking.hostName = "minio";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -8,8 +8,6 @@ in
{ {
imports = [ ]; imports = [ ];
networking.hostName = "mosquitto";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -24,8 +24,6 @@ let
''; '';
in in
{ {
networking.hostName = "nginx";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -11,8 +11,6 @@ in
{ {
imports = [ ]; imports = [ ];
networking.hostName = "synapse";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -7,8 +7,6 @@
{ {
imports = [ ]; imports = [ ];
networking.hostName = "unifi";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -5,8 +5,6 @@
{ config, pkgs, ... }: { config, pkgs, ... }:
let port = 8200; let port = 8200;
in { in {
networking.hostName = "vault";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -10,8 +10,6 @@ in
{ {
imports = [ ]; imports = [ ];
networking.hostName = "victoriametrics";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave

View file

@ -7,8 +7,6 @@ let vs = config.vault-secrets.secrets; in
{ {
imports = [ ]; imports = [ ];
networking.hostName = "wireguard";
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave # on your system were taken. Its perfectly fine and recommended to leave