From 51b333636ed469f30a4bbfd6dfd24f31098c1fbd Mon Sep 17 00:00:00 2001 From: 0xTux <0xtux@pm.me> Date: Fri, 13 Sep 2024 20:44:58 +0530 Subject: [PATCH] change controller hostname to arcturus --- .sops.yaml | 6 +++--- flake.nix | 6 +++--- hosts/{controller => arcturus}/default.nix | 7 ++++--- hosts/{controller => arcturus}/hardware-configuration.nix | 0 hosts/{controller => arcturus}/home.nix | 0 hosts/{controller => arcturus}/secrets.yaml | 0 6 files changed, 10 insertions(+), 9 deletions(-) rename hosts/{controller => arcturus}/default.nix (94%) rename hosts/{controller => arcturus}/hardware-configuration.nix (100%) rename hosts/{controller => arcturus}/home.nix (100%) rename hosts/{controller => arcturus}/secrets.yaml (100%) diff --git a/.sops.yaml b/.sops.yaml index 2749e90..1489863 100644 --- a/.sops.yaml +++ b/.sops.yaml @@ -4,7 +4,7 @@ keys: - &hosts - &canopus age1cc9phftkzcwaey2rw63m74tyxdjxxzanxphsdrhy6vwlwhgehfzq9rh6e4 - - &controller age1zsl5d4vj6gl3h96y5p53sq5y4vr4vtlwp727h7rp9a4xfkxm53lqrh6r50 + - &arcturus age1zsl5d4vj6gl3h96y5p53sq5y4vr4vtlwp727h7rp9a4xfkxm53lqrh6r50 - &alpha age145uq9emlxqzm3wqauy9zqj78wqx9e6h09xag6wust7jjgn4upfzsaemcvx - &wsl age1lyvzg4ud96trsuv6gsvjw0p3rtd6qjpyl9uleq8hcrzwekuhpfesnlqauf @@ -14,7 +14,7 @@ creation_rules: - age: - *tux - *canopus - - *controller + - *arcturus - *alpha - *wsl - path_regex: hosts/canopus/secrets.yaml$ @@ -26,7 +26,7 @@ creation_rules: key_groups: - age: - *tux - - *controller + - *arcturus - path_regex: hosts/alpha/secrets.yaml$ key_groups: - age: diff --git a/flake.nix b/flake.nix index f8daae0..05d6cac 100755 --- a/flake.nix +++ b/flake.nix @@ -65,10 +65,10 @@ ]; }; - controller = nixpkgs.lib.nixosSystem { + arcturus = nixpkgs.lib.nixosSystem { specialArgs = {inherit inputs outputs username;}; modules = [ - ./hosts/controller + ./hosts/arcturus home-manager.nixosModules.home-manager { @@ -77,7 +77,7 @@ home-manager.extraSpecialArgs = {inherit inputs outputs username;}; home-manager.users.${username} = { imports = [ - ./hosts/controller/home.nix + ./hosts/arcturus/home.nix ]; }; } diff --git a/hosts/controller/default.nix b/hosts/arcturus/default.nix similarity index 94% rename from hosts/controller/default.nix rename to hosts/arcturus/default.nix index bb118e9..858e825 100644 --- a/hosts/controller/default.nix +++ b/hosts/arcturus/default.nix @@ -46,7 +46,8 @@ }; networking = { - hostName = "controller"; + hostName = "arcturus"; + firewall = { enable = true; allowedTCPPorts = [80 443 22]; @@ -83,7 +84,7 @@ recommendedTlsSettings = true; }; - borgbackup.jobs.controller-backup = { + borgbackup.jobs.arcturus-backup = { paths = [ "/var/lib/bitwarden_rs" "/var/lib/gitea" @@ -97,7 +98,7 @@ passCommand = "cat ${config.sops.secrets.borg_encryption_key.path}"; }; environment.BORG_RSH = "ssh -i /home/${username}/.ssh/storagebox"; - repo = "ssh://u416910@u416910.your-storagebox.de:23/./controller-backups"; + repo = "ssh://u416910@u416910.your-storagebox.de:23/./arcturus-backups"; compression = "auto,zstd"; startAt = "daily"; }; diff --git a/hosts/controller/hardware-configuration.nix b/hosts/arcturus/hardware-configuration.nix similarity index 100% rename from hosts/controller/hardware-configuration.nix rename to hosts/arcturus/hardware-configuration.nix diff --git a/hosts/controller/home.nix b/hosts/arcturus/home.nix similarity index 100% rename from hosts/controller/home.nix rename to hosts/arcturus/home.nix diff --git a/hosts/controller/secrets.yaml b/hosts/arcturus/secrets.yaml similarity index 100% rename from hosts/controller/secrets.yaml rename to hosts/arcturus/secrets.yaml