adding h002 back in
This commit is contained in:
parent
ea9340a612
commit
acfec76a79
11 changed files with 1014 additions and 131 deletions
|
|
@ -1,13 +1,15 @@
|
|||
{
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05";
|
||||
# nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.11";
|
||||
home-manager.url = "github:rycee/home-manager/release-25.11";
|
||||
|
||||
# Use relative to get current version for testing
|
||||
# common.url = "path:../../common";
|
||||
common.url = "git+https://git.joshuabell.xyz/ringofstorms/dotfiles";
|
||||
common.url = "git+https://git.joshuabell.xyz/ringofstorms/dotfiles?dir=flakes/common";
|
||||
# de_plasma.url = "path:../../../../flakes/de_plasma";
|
||||
de_plasma.url = "git+https://git.joshuabell.xyz/ringofstorms/dotfiles?dir=flakes/de_plasma";
|
||||
|
||||
ros_neovim.url = "git+https://git.joshuabell.xyz/ringofstorms/nvim";
|
||||
|
||||
impermanence.url = "github:nix-community/impermanence";
|
||||
};
|
||||
|
||||
outputs =
|
||||
|
|
@ -16,92 +18,122 @@
|
|||
common,
|
||||
ros_neovim,
|
||||
...
|
||||
}:
|
||||
}@inputs:
|
||||
let
|
||||
configuration_name = "h002";
|
||||
lib = nixpkgs.lib;
|
||||
configurationName = "h002";
|
||||
primaryUser = "luser";
|
||||
configLocation = "/home/${primaryUser}/.config/nixos-config/hosts/${configurationName}";
|
||||
stateAndHomeVersion = "25.11";
|
||||
# overlayIp = "100.64.0.14";
|
||||
lib = inputs.nixpkgs.lib;
|
||||
in
|
||||
{
|
||||
nixosConfigurations = {
|
||||
"${configuration_name}" = (
|
||||
"${configurationName}" = (
|
||||
lib.nixosSystem {
|
||||
specialArgs = {
|
||||
inherit inputs;
|
||||
};
|
||||
modules = [
|
||||
common.nixosModules.default
|
||||
ros_neovim.nixosModules.default
|
||||
./configuration.nix
|
||||
./hardware-configuration.nix
|
||||
(
|
||||
{ config, pkgs, ... }:
|
||||
{
|
||||
environment.systemPackages = with pkgs; [
|
||||
lua
|
||||
qdirstat
|
||||
];
|
||||
inputs.impermanence.nixosModules.impermanence
|
||||
inputs.home-manager.nixosModules.default
|
||||
|
||||
ringofstorms_common = {
|
||||
systemName = configuration_name;
|
||||
boot.grub.enable = true;
|
||||
secrets.enable = true;
|
||||
desktopEnvironment.gnome.enable = true;
|
||||
general = {
|
||||
reporting.enable = true;
|
||||
# TODO
|
||||
# secrets.nixosModules.default
|
||||
inputs.ros_neovim.nixosModules.default
|
||||
({
|
||||
ringofstorms-nvim.includeAllRuntimeDependencies = true;
|
||||
})
|
||||
|
||||
inputs.common.nixosModules.essentials
|
||||
inputs.common.nixosModules.git
|
||||
inputs.common.nixosModules.tmux
|
||||
inputs.common.nixosModules.boot_grub
|
||||
({
|
||||
boot.loader.grub.device = "/dev/sdb";
|
||||
})
|
||||
inputs.common.nixosModules.hardening
|
||||
inputs.common.nixosModules.nix_options
|
||||
inputs.common.nixosModules.no_sleep
|
||||
inputs.common.nixosModules.timezone_auto
|
||||
inputs.common.nixosModules.tty_caps_esc
|
||||
inputs.common.nixosModules.zsh
|
||||
# TODO
|
||||
# common.nixosModules.tailnet
|
||||
# beszel.nixosModules.agent
|
||||
# (
|
||||
# { ... }:
|
||||
# {
|
||||
# beszelAgent = {
|
||||
# listen = "${overlayIp}:45876";
|
||||
# token = "f8a54c41-486b-487a-a78d-a087385c317b";
|
||||
# };
|
||||
# }
|
||||
# )
|
||||
|
||||
./hardware-configuration.nix
|
||||
./hardware-mounts.nix
|
||||
./impermanence.nix
|
||||
./impermanence-tools.nix
|
||||
(
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
rec {
|
||||
system.stateVersion = stateAndHomeVersion;
|
||||
|
||||
# Home Manager
|
||||
home-manager = {
|
||||
useUserPackages = true;
|
||||
useGlobalPkgs = true;
|
||||
backupFileExtension = "bak";
|
||||
# add all normal users to home manager so it applies to them
|
||||
users = lib.mapAttrs (name: user: {
|
||||
home.stateVersion = stateAndHomeVersion;
|
||||
programs.home-manager.enable = true;
|
||||
}) (lib.filterAttrs (name: user: user.isNormalUser or false) users.users);
|
||||
|
||||
sharedModules = [
|
||||
inputs.common.homeManagerModules.tmux
|
||||
inputs.common.homeManagerModules.atuin
|
||||
inputs.common.homeManagerModules.direnv
|
||||
inputs.common.homeManagerModules.git
|
||||
inputs.common.homeManagerModules.postgres_cli_options
|
||||
inputs.common.homeManagerModules.starship
|
||||
inputs.common.homeManagerModules.zoxide
|
||||
inputs.common.homeManagerModules.zsh
|
||||
];
|
||||
|
||||
extraSpecialArgs = {
|
||||
inherit inputs;
|
||||
};
|
||||
programs = {
|
||||
qFlipper.enable = true;
|
||||
rustDev.enable = true;
|
||||
tailnet.enable = true;
|
||||
ssh.enable = true;
|
||||
docker.enable = true;
|
||||
uhkAgent.enable = true;
|
||||
};
|
||||
users = {
|
||||
admins = [ "luser" ]; # First admin is also the primary user owning nix config
|
||||
users = {
|
||||
root = {
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJie9OPheWn/EZWfXJSZ3S0DnISqI3ToCmOqhX/Tkwby nix2h002"
|
||||
];
|
||||
};
|
||||
luser = {
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJie9OPheWn/EZWfXJSZ3S0DnISqI3ToCmOqhX/Tkwby nix2h002"
|
||||
];
|
||||
extraGroups = [
|
||||
"networkmanager"
|
||||
"video"
|
||||
"input"
|
||||
];
|
||||
shell = pkgs.zsh;
|
||||
packages = with pkgs; [
|
||||
bitwarden
|
||||
vaultwarden
|
||||
google-chrome
|
||||
firefox-esr
|
||||
openscad
|
||||
vlc
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
homeManager = {
|
||||
users = {
|
||||
luser = {
|
||||
imports = with common.homeManagerModules; [
|
||||
kitty
|
||||
tmux
|
||||
atuin
|
||||
direnv
|
||||
git
|
||||
nix_deprecations
|
||||
postgres
|
||||
ssh
|
||||
starship
|
||||
zoxide
|
||||
zsh
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# System configuration
|
||||
networking.networkmanager.enable = true;
|
||||
networking.hostName = configurationName;
|
||||
programs.nh.flake = configLocation;
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
# users.mutableUsers = false;
|
||||
users.users = {
|
||||
"${primaryUser}" = {
|
||||
isNormalUser = true;
|
||||
# hashedPassword = ""; # Use if mutable users is false above
|
||||
initialHashedPassword = "$y$j9T$v1QhXiZMRY1pFkPmkLkdp0$451GvQt.XFU2qCAi4EQNd1BEqjM/CH6awU8gjcULps6"; # "test" password
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"networkmanager"
|
||||
];
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH2KFSRkViT+asBTjCgA7LNP3SHnfNCW+jHbV08VUuIi nix2nix"
|
||||
];
|
||||
};
|
||||
root.openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH2KFSRkViT+asBTjCgA7LNP3SHnfNCW+jHbV08VUuIi nix2nix"
|
||||
];
|
||||
};
|
||||
}
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue