Compare commits
5 Commits
b0aadbf43b
...
c239d8dbda
| Author | SHA1 | Date | |
|---|---|---|---|
| c239d8dbda | |||
| 0cd3f5ce32 | |||
| e442f610c3 | |||
| 3ae5cba9a6 | |||
| c2d233b3fa |
9
.gitignore
vendored
9
.gitignore
vendored
@@ -1 +1,10 @@
|
||||
.claude
|
||||
docs/
|
||||
|
||||
# secret guardrails — keep credentials out of the repo
|
||||
secrets/
|
||||
*.age
|
||||
*.key
|
||||
*.pem
|
||||
.env
|
||||
.env.*
|
||||
|
||||
12
README.md
Normal file
12
README.md
Normal file
@@ -0,0 +1,12 @@
|
||||
What's verified:
|
||||
- nix flake check passes for both hivebrain and nikita-nixos
|
||||
- nixos-rebuild dry-build --flake .#hivebrain succeeds (your config is unchanged in behavior)
|
||||
- nixos-rebuild dry-build --flake .#nikita-nixos succeeds (Plasma 6 + SDDM derivation resolves)
|
||||
- main is untouched
|
||||
|
||||
What's still TODO before you can install nikita-nixos:
|
||||
- Replace hosts/nikita-nixos/hardware-configuration.nix (placeholder with PLACEHOLDER-ROOT label) with
|
||||
the real output of nixos-generate-config --root /mnt on his machine.
|
||||
- Replace the placeholder git identity in hosts/nikita-nixos/home.nix (currently Nikita /
|
||||
nikita@example.com).
|
||||
- Set Nikita's password with passwd after first boot — nothing is baked in.
|
||||
@@ -1,21 +0,0 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./system/boot.nix
|
||||
./system/networking.nix
|
||||
./system/locale.nix
|
||||
./system/xserver.nix
|
||||
./system/picom.nix
|
||||
./system/display-manager.nix
|
||||
./system/fonts.nix
|
||||
./system/users.nix
|
||||
./system/programs.nix
|
||||
./system/packages.nix
|
||||
./system/ssh.nix
|
||||
./system/nix.nix
|
||||
];
|
||||
|
||||
system.stateVersion = "26.05";
|
||||
}
|
||||
20
flake.nix
20
flake.nix
@@ -9,20 +9,32 @@
|
||||
};
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, home-manager, ... }: {
|
||||
nixosConfigurations.hivebrain = nixpkgs.lib.nixosSystem {
|
||||
outputs = { self, nixpkgs, home-manager, ... }:
|
||||
let
|
||||
mkHost = { hostPath, username, homePath }: nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
./configuration.nix
|
||||
hostPath
|
||||
home-manager.nixosModules.home-manager {
|
||||
home-manager = {
|
||||
useGlobalPkgs = true;
|
||||
useUserPackages = true;
|
||||
users.marvin = import ./home.nix;
|
||||
users.${username} = import homePath;
|
||||
backupFileExtension = "backup";
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
in {
|
||||
nixosConfigurations.hivebrain = mkHost {
|
||||
hostPath = ./hosts/hivebrain;
|
||||
username = "marvin";
|
||||
homePath = ./hosts/hivebrain/home.nix;
|
||||
};
|
||||
nixosConfigurations.nikita-nixos = mkHost {
|
||||
hostPath = ./hosts/nikita-nixos;
|
||||
username = "nikita";
|
||||
homePath = ./hosts/nikita-nixos/home.nix;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
17
home.nix
17
home.nix
@@ -1,17 +0,0 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./home/zsh.nix
|
||||
./home/git.nix
|
||||
./home/rofi.nix
|
||||
./home/yazi.nix
|
||||
./home/packages.nix
|
||||
./home/symlinks.nix
|
||||
./home/fonts.nix
|
||||
];
|
||||
|
||||
home.username = "marvin";
|
||||
home.homeDirectory = "/home/marvin";
|
||||
home.stateVersion = "26.05";
|
||||
}
|
||||
11
home/git.nix
11
home/git.nix
@@ -1,11 +0,0 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
programs.git = {
|
||||
enable = true;
|
||||
settings.user = {
|
||||
name = "MDietermann";
|
||||
email = "marvin.dietermann@hive-brain.de";
|
||||
};
|
||||
};
|
||||
}
|
||||
10
home/packages-base.nix
Normal file
10
home/packages-base.nix
Normal file
@@ -0,0 +1,10 @@
|
||||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
neovim
|
||||
nerd-fonts.jetbrains-mono
|
||||
ripgrep
|
||||
unzip
|
||||
];
|
||||
}
|
||||
@@ -6,17 +6,13 @@
|
||||
claude-code
|
||||
gcc
|
||||
lua-language-server
|
||||
neovim
|
||||
nerd-fonts.jetbrains-mono
|
||||
nil
|
||||
nixpkgs-fmt
|
||||
nodejs
|
||||
obsidian
|
||||
pkg-config
|
||||
ripgrep
|
||||
rustup
|
||||
steam
|
||||
unzip
|
||||
xwallpaper
|
||||
];
|
||||
}
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
shellAliases = {
|
||||
btw = "echo I use NixOS";
|
||||
reload-nixos = "sudo nixos-rebuild switch --flake ~/nixos-dotfiles#hivebrain";
|
||||
reload-nixos = "sudo nixos-rebuild switch --flake ~/nixos-dotfiles";
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
26
hosts/hivebrain/default.nix
Normal file
26
hosts/hivebrain/default.nix
Normal file
@@ -0,0 +1,26 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
|
||||
# shared
|
||||
../../system/boot.nix
|
||||
../../system/networking.nix
|
||||
../../system/locale.nix
|
||||
../../system/fonts.nix
|
||||
../../system/nix.nix
|
||||
../../system/ssh.nix
|
||||
../../system/programs.nix
|
||||
../../system/packages.nix
|
||||
|
||||
# marvin-only
|
||||
../../system/xserver.nix
|
||||
../../system/picom.nix
|
||||
../../system/display-managers/ly.nix
|
||||
../../system/users/marvin.nix
|
||||
];
|
||||
|
||||
networking.hostName = "hivebrain";
|
||||
system.stateVersion = "26.05";
|
||||
}
|
||||
25
hosts/hivebrain/home.nix
Normal file
25
hosts/hivebrain/home.nix
Normal file
@@ -0,0 +1,25 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../home/zsh.nix
|
||||
../../home/fonts.nix
|
||||
../../home/rofi.nix
|
||||
../../home/yazi.nix
|
||||
../../home/symlinks.nix
|
||||
../../home/packages-base.nix
|
||||
../../home/packages-marvin.nix
|
||||
];
|
||||
|
||||
home.username = "marvin";
|
||||
home.homeDirectory = "/home/marvin";
|
||||
home.stateVersion = "26.05";
|
||||
|
||||
programs.git = {
|
||||
enable = true;
|
||||
settings.user = {
|
||||
name = "MDietermann";
|
||||
email = "marvin.dietermann@hive-brain.de";
|
||||
};
|
||||
};
|
||||
}
|
||||
24
hosts/nikita-nixos/default.nix
Normal file
24
hosts/nikita-nixos/default.nix
Normal file
@@ -0,0 +1,24 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
|
||||
# shared
|
||||
../../system/boot.nix
|
||||
../../system/networking.nix
|
||||
../../system/locale.nix
|
||||
../../system/fonts.nix
|
||||
../../system/nix.nix
|
||||
../../system/programs.nix
|
||||
../../system/packages.nix
|
||||
|
||||
# nikita-only
|
||||
../../system/plasma.nix
|
||||
../../system/display-managers/sddm.nix
|
||||
../../system/users/nikita.nix
|
||||
];
|
||||
|
||||
networking.hostName = "nikita-nixos";
|
||||
system.stateVersion = "26.05";
|
||||
}
|
||||
24
hosts/nikita-nixos/hardware-configuration.nix
Normal file
24
hosts/nikita-nixos/hardware-configuration.nix
Normal file
@@ -0,0 +1,24 @@
|
||||
{ lib, modulesPath, ... }:
|
||||
|
||||
# Placeholder hardware-configuration. Replace with the file generated on
|
||||
# Nikita's actual machine via `nixos-generate-config --root /mnt` before
|
||||
# building or installing.
|
||||
{
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-label/PLACEHOLDER-ROOT";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
}
|
||||
24
hosts/nikita-nixos/home.nix
Normal file
24
hosts/nikita-nixos/home.nix
Normal file
@@ -0,0 +1,24 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../home/zsh.nix
|
||||
../../home/fonts.nix
|
||||
../../home/yazi.nix
|
||||
../../home/symlinks.nix
|
||||
../../home/packages-base.nix
|
||||
];
|
||||
|
||||
home.username = "nikita";
|
||||
home.homeDirectory = "/home/nikita";
|
||||
home.stateVersion = "26.05";
|
||||
|
||||
# TODO: replace with Nikita's actual git identity before first use
|
||||
programs.git = {
|
||||
enable = true;
|
||||
settings.user = {
|
||||
name = "Nikita";
|
||||
email = "nikita@example.com";
|
||||
};
|
||||
};
|
||||
}
|
||||
5
system/display-managers/sddm.nix
Normal file
5
system/display-managers/sddm.nix
Normal file
@@ -0,0 +1,5 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
services.displayManager.sddm.enable = true;
|
||||
}
|
||||
@@ -1,6 +1,5 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
networking.hostName = "hivebrain";
|
||||
networking.networkmanager.enable = true;
|
||||
}
|
||||
|
||||
5
system/plasma.nix
Normal file
5
system/plasma.nix
Normal file
@@ -0,0 +1,5 @@
|
||||
{ ... }:
|
||||
|
||||
{
|
||||
services.desktopManager.plasma6.enable = true;
|
||||
}
|
||||
12
system/users/nikita.nix
Normal file
12
system/users/nikita.nix
Normal file
@@ -0,0 +1,12 @@
|
||||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
users.users.nikita = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" "networkmanager" ];
|
||||
shell = pkgs.zsh;
|
||||
packages = with pkgs; [
|
||||
tree
|
||||
];
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user