Skip to content

Leveraging nix, nix-os, nix-darwin, and home-manager to apply machine and home configurations

License

Notifications You must be signed in to change notification settings

billimek/dotfiles

Repository files navigation

Leveraging nix, nix-os, nix-darwin, and home-manager to apply machine and home configurations

Structure

  • flake.nix (Entrypoint for rebuilding via nixos-rebuild or home-manager)
  • flake.lock (lockfile for current nix flake state, updated daily via github action)
    • home-manager (User level configuration per machine via home-manager)
    • hosts - (Definition of physical/virutal hosts)
      • common (Role definitions [Desktop, Laptop, Server])
        • darwin (global host configuration used across all darwin hosts)
        • nixos (global host configuration used across all NixOS hosts)
        • optional (optional host configuration used as-needed per host)
      • nas (NixOS NAS server)
      • home (NixOS VM running in NAS)
      • cloud (NixOS VM running in Oracle Cloud)
      • k3s-f (NixOS running on an N100 tiny PC as a k3s node)
      • k3s-g (NixOS running on an N100 tiny PC as a k3s node)
      • k3s-h (NixOS running on an N100 tiny PC as a k3s node)
      • jeffs_laptop (nix-darwin running on a MacBook Pro)
      • work_laptop (nix-darwin running on a MacBook Pro)
    • modules (Custom NixOS and home-manager modules)
    • overlays (Custom overlays, primarily used for packages currently)
    • pkgs (Custom Packages, mainly items not yet in official nixpkgs)
  • shell.nix (Shell for bootstrapping flake-enabled nix and home-manager)
  • nixpkgs.nix (Used by shell.nix - useful to avoid using channels when using legacy nix commands)

Background

Everyone keeps gushing about how amazing Nix is and I want to get in on the hype cycle

Goals

  • Learn nix
  • Mostly reproduce features from my existing dotfiles
  • Replace existing ubunut-based 'home VM'
  • Expand usage to other shell environments such as WSL, Macbook, etc
  • handle secrets - ideally using 1Password and not SOPS - using git-crypt for now
  • try agenix for secrets handling
  • introduce the concept of impermanence where appropriate

References

Old Dotfiles

Old dotfiles are still accessible in archive branch

About

Leveraging nix, nix-os, nix-darwin, and home-manager to apply machine and home configurations

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages