Added sops, updated readme, added main config

This commit is contained in:
Alexander Derevianko
2025-07-26 14:35:38 +02:00
parent baf2f6438f
commit 274872ec95
11 changed files with 446 additions and 6 deletions
+43 -2
View File
@@ -1,7 +1,8 @@
{ config, pkgs, extraHomeModules, inputs, ... }:
{ config, pkgs, extraHomeModules, inputs, lib, ... }:
let
username = "susano";
flakeInputs = lib.filterAttrs (_: lib.isType "flake") inputs;
in {
imports =
[ # Include the results of the hardware scan.
@@ -9,6 +10,46 @@ in {
./disko-config.nix
];
nixpkgs = {
# You can add overlays here
overlays = [
# If you want to use overlays exported from other flakes:
# neovim-nightly-overlay.overlays.default
# Or define it inline, for example:
# (final: prev: {
# hi = final.hello.overrideAttrs (oldAttrs: {
# patches = [ ./change-hello-to-hi.patch ];
# });
# })
];
# Configure your nixpkgs instance
config = {
# Disable if you don't want unfree packages
allowUnfree = true;
};
};
nix = {
settings = {
# Enable flakes and new 'nix' command
experimental-features = "nix-command flakes";
# Opinionated: disable global registry
flake-registry = "";
# Workaround for https://github.com/NixOS/nix/issues/9574
nix-path = config.nix.nixPath;
# Allow user to reubild nixos without sudo
trusted-users = [ "root" username ];
};
# Opinionated: disable channels
channel.enable = false;
# Opinionated: make flake registry and nix path match flake inputs
registry = lib.mapAttrs (_: flake: {inherit flake;}) flakeInputs;
nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
};
# Bootloader.
boot.loader.grub.enable = true;
boot.loader.grub.useOSProber = true;
@@ -39,7 +80,7 @@ in {
users.users.${username} = {
isNormalUser = true;
description = "NixOS Proxmox Homelab";
initialPassword = "test";
hashedPassword = "$6$7LSgOtcEozV0gkN9$pCltKL683UqJ3M7C4ZIgZsytAGtQS375g64ckuJQPFtUjxiGCxehJtkP91Pba.rIZNe3eZqnJfIQNwnJWmyVJ0";
extraGroups = [ "networkmanager" "wheel" ];
packages = with pkgs; [
];