aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2025-12-14 13:08:07 -0800
committerFranck Cuny <franck@fcuny.net>2025-12-14 13:08:07 -0800
commit05fba25e608d3d44e0785f1ddb5ab30a95129131 (patch)
tree60a2a563002079282873afad59d296958f978fce
parentuse `just` (again) instead of custom scripts (diff)
downloadinfra-05fba25e608d3d44e0785f1ddb5ab30a95129131.tar.gz
simplify path structures for machines
Diffstat (limited to '')
-rw-r--r--flake.nix12
-rw-r--r--machines/HQ-KWNY2VH41P.nix (renamed from machines/darwin/aarch64-darwin/HQ-KWNY2VH41P.nix)8
-rw-r--r--machines/argonath.nix25
-rw-r--r--machines/bree.nix (renamed from machines/nixos/x86_64-linux/bree.nix)22
-rw-r--r--machines/iso.nix (renamed from machines/nixos/x86_64-linux/iso.nix)6
-rw-r--r--machines/mba-m2.nix (renamed from machines/darwin/aarch64-darwin/mba-m2.nix)14
-rw-r--r--machines/nixos/x86_64-linux/argonath.nix25
-rw-r--r--machines/rivendell.nix (renamed from machines/nixos/x86_64-linux/rivendell.nix)32
8 files changed, 72 insertions, 72 deletions
diff --git a/flake.nix b/flake.nix
index 23d1c44..ec2f077 100644
--- a/flake.nix
+++ b/flake.nix
@@ -114,29 +114,29 @@
nixos = {
rivendell = {
system = "x86_64-linux";
- config = ./machines/nixos/x86_64-linux/rivendell.nix;
+ config = ./machines/rivendell.nix;
};
bree = {
system = "x86_64-linux";
- config = ./machines/nixos/x86_64-linux/bree.nix;
+ config = ./machines/bree.nix;
};
argonath = {
system = "x86_64-linux";
- config = ./machines/nixos/x86_64-linux/argonath.nix;
+ config = ./machines/argonath.nix;
};
iso = {
system = "x86_64-linux";
- config = ./machines/nixos/x86_64-linux/iso.nix;
+ config = ./machines/iso.nix;
};
};
darwin = {
mba-m2 = {
system = "aarch64-darwin";
- config = ./machines/darwin/aarch64-darwin/mba-m2.nix;
+ config = ./machines/mba-m2.nix;
};
HQ-KWNY2VH41P = {
system = "aarch64-darwin";
- config = ./machines/darwin/aarch64-darwin/HQ-KWNY2VH41P.nix;
+ config = ./machines/HQ-KWNY2VH41P.nix;
};
};
};
diff --git a/machines/darwin/aarch64-darwin/HQ-KWNY2VH41P.nix b/machines/HQ-KWNY2VH41P.nix
index 52dc522..fc4340d 100644
--- a/machines/darwin/aarch64-darwin/HQ-KWNY2VH41P.nix
+++ b/machines/HQ-KWNY2VH41P.nix
@@ -1,8 +1,8 @@
{ pkgs, ... }:
{
imports = [
- ../../../profiles/darwin.nix
- ../../../profiles/home-manager.nix
+ ../profiles/darwin.nix
+ ../profiles/home-manager.nix
];
users.users.fcuny = {
@@ -26,8 +26,8 @@
home.username = "fcuny";
home.homeDirectory = "/Users/fcuny";
imports = [
- ../../../home/profiles/mac.nix
- ../../../home/profiles/work.nix
+ ../home/profiles/mac.nix
+ ../home/profiles/work.nix
];
userinfo = {
email = "fcuny@roblox.com";
diff --git a/machines/argonath.nix b/machines/argonath.nix
new file mode 100644
index 0000000..b99e83f
--- /dev/null
+++ b/machines/argonath.nix
@@ -0,0 +1,25 @@
+{ ... }:
+{
+ imports = [
+ ../profiles/acme.nix
+ ../profiles/cgroups.nix
+ ../profiles/defaults.nix
+ ../profiles/disk/basic-vm.nix
+ ../profiles/hardware/do-droplet.nix
+ ../profiles/home-manager.nix
+ ../profiles/reverse-proxy.nix
+ ../profiles/server.nix
+ ../profiles/wireguard.nix
+ ../profiles/users/fcuny.nix
+ ];
+
+ networking.hostName = "argonath";
+
+ system.stateVersion = "25.05"; # Did you read the comment?
+
+ home-manager.users.fcuny = {
+ imports = [
+ ../home/profiles/minimal.nix
+ ];
+ };
+}
diff --git a/machines/nixos/x86_64-linux/bree.nix b/machines/bree.nix
index 9c9177d..e4cd443 100644
--- a/machines/nixos/x86_64-linux/bree.nix
+++ b/machines/bree.nix
@@ -1,22 +1,22 @@
{ lib, config, ... }:
{
imports = [
- ../../../profiles/cgroups.nix
- ../../../profiles/defaults.nix
- ../../../profiles/disk/basic-vm.nix
- ../../../profiles/hardware/synology-vm.nix
- ../../../profiles/home-manager.nix
- ../../../profiles/server.nix
- ../../../profiles/users/fcuny.nix
- ../../../profiles/wireguard.nix
+ ../profiles/cgroups.nix
+ ../profiles/defaults.nix
+ ../profiles/disk/basic-vm.nix
+ ../profiles/hardware/synology-vm.nix
+ ../profiles/home-manager.nix
+ ../profiles/server.nix
+ ../profiles/users/fcuny.nix
+ ../profiles/wireguard.nix
];
networking.hostName = "bree";
networking.useDHCP = lib.mkDefault true;
systemd.network.wait-online.anyInterface = lib.mkDefault config.networking.useDHCP;
- age.secrets.disk-unlock-key.file = ../../../secrets/bree/disk-unlock-key.age;
- age.secrets.disk-passphrase.file = ../../../secrets/bree/disk-passphrase.age;
+ age.secrets.disk-unlock-key.file = ../secrets/bree/disk-unlock-key.age;
+ age.secrets.disk-passphrase.file = ../secrets/bree/disk-passphrase.age;
services.remoteDiskUnlock = {
enable = true;
@@ -31,7 +31,7 @@
home-manager.users.fcuny = {
imports = [
- ../../../home/profiles/minimal.nix
+ ../home/profiles/minimal.nix
];
};
}
diff --git a/machines/nixos/x86_64-linux/iso.nix b/machines/iso.nix
index fc9c4fa..a636508 100644
--- a/machines/nixos/x86_64-linux/iso.nix
+++ b/machines/iso.nix
@@ -4,8 +4,8 @@
imports = [
"${modulesPath}/installer/cd-dvd/channel.nix"
"${modulesPath}/installer/cd-dvd/installation-cd-minimal.nix"
- ../../../profiles/home-manager.nix
- ../../../profiles/users/fcuny.nix
+ ../profiles/home-manager.nix
+ ../profiles/users/fcuny.nix
];
boot.loader.grub.efiSupport = true;
@@ -18,7 +18,7 @@
home-manager.users.fcuny = {
imports = [
- ../../../home/profiles/minimal.nix
+ ../home/profiles/minimal.nix
];
};
}
diff --git a/machines/darwin/aarch64-darwin/mba-m2.nix b/machines/mba-m2.nix
index 08a27c1..398bf6d 100644
--- a/machines/darwin/aarch64-darwin/mba-m2.nix
+++ b/machines/mba-m2.nix
@@ -1,13 +1,13 @@
{ pkgs, ... }:
{
age.secrets = {
- ssh-remote-builder.file = ../../../secrets/ssh-remote-builder.age;
+ ssh-remote-builder.file = ../secrets/ssh-remote-builder.age;
};
imports = [
- ../../../profiles/darwin.nix
- ../../../profiles/home-manager.nix
- ../../../profiles/remote-builder.nix
+ ../profiles/darwin.nix
+ ../profiles/home-manager.nix
+ ../profiles/remote-builder.nix
];
# https://github.com/nix-darwin/nix-darwin/issues/1339
@@ -40,9 +40,9 @@
hledger
];
imports = [
- ../../../home/profiles/mac.nix
- ../../../home/profiles/media.nix
- ../../../home/profiles/security.nix
+ ../home/profiles/mac.nix
+ ../home/profiles/media.nix
+ ../home/profiles/security.nix
];
userinfo = {
email = "franck@fcuny.net";
diff --git a/machines/nixos/x86_64-linux/argonath.nix b/machines/nixos/x86_64-linux/argonath.nix
deleted file mode 100644
index 3dda772..0000000
--- a/machines/nixos/x86_64-linux/argonath.nix
+++ /dev/null
@@ -1,25 +0,0 @@
-{ ... }:
-{
- imports = [
- ../../../profiles/acme.nix
- ../../../profiles/cgroups.nix
- ../../../profiles/defaults.nix
- ../../../profiles/disk/basic-vm.nix
- ../../../profiles/hardware/do-droplet.nix
- ../../../profiles/home-manager.nix
- ../../../profiles/reverse-proxy.nix
- ../../../profiles/server.nix
- ../../../profiles/wireguard.nix
- ../../../profiles/users/fcuny.nix
- ];
-
- networking.hostName = "argonath";
-
- system.stateVersion = "25.05"; # Did you read the comment?
-
- home-manager.users.fcuny = {
- imports = [
- ../../../home/profiles/minimal.nix
- ];
- };
-}
diff --git a/machines/nixos/x86_64-linux/rivendell.nix b/machines/rivendell.nix
index 0bd799c..4940ea3 100644
--- a/machines/nixos/x86_64-linux/rivendell.nix
+++ b/machines/rivendell.nix
@@ -1,21 +1,21 @@
{ lib, config, ... }:
{
imports = [
- ../../../profiles/authelia.nix
- ../../../profiles/cgroups.nix
- ../../../profiles/defaults.nix
- ../../../profiles/disk/btrfs-on-luks.nix
- ../../../profiles/git-server.nix
- ../../../profiles/hardware/framework-desktop.nix
- ../../../profiles/home-manager.nix
- ../../../profiles/makemkv.nix
- ../../../profiles/miniflux.nix
- ../../../profiles/remote-unlock.nix
- ../../../profiles/restic-backup.nix
- ../../../profiles/server.nix
- ../../../profiles/users/builder.nix
- ../../../profiles/users/fcuny.nix
- ../../../profiles/wireguard.nix
+ ../profiles/authelia.nix
+ ../profiles/cgroups.nix
+ ../profiles/defaults.nix
+ ../profiles/disk/btrfs-on-luks.nix
+ ../profiles/git-server.nix
+ ../profiles/hardware/framework-desktop.nix
+ ../profiles/home-manager.nix
+ ../profiles/makemkv.nix
+ ../profiles/miniflux.nix
+ ../profiles/remote-unlock.nix
+ ../profiles/restic-backup.nix
+ ../profiles/server.nix
+ ../profiles/users/builder.nix
+ ../profiles/users/fcuny.nix
+ ../profiles/wireguard.nix
];
networking.hostName = "rivendell";
@@ -72,7 +72,7 @@
home-manager.users.fcuny = {
imports = [
- ../../../home/profiles/minimal.nix
+ ../home/profiles/minimal.nix
];
};
}