Readme file

This commit is contained in:
Filippo Berto 2026-02-02 10:49:02 +01:00
parent 2437fd2173
commit 1a7cfd9b0a
No known key found for this signature in database
GPG key ID: F1D17F9BCEC62FBC
2 changed files with 129 additions and 0 deletions

4
.markdownlint.json Normal file
View file

@ -0,0 +1,4 @@
{
"default": true,
"MD013": false
}

125
README.md Normal file
View file

@ -0,0 +1,125 @@
# bertof's NixOS Dotfiles
Personal NixOS configuration repository using flake-parts for modular system management across multiple hosts.
## Architecture
### Structure
- **`flake.nix`** - Main flake definition with flake-parts modularization
- **`instances/`** - Host-specific configurations (thor, sif, odin, heimdall, baldur)
- **`hm/`** - Home Manager modules and user configurations
- **`nixos/`** - NixOS system modules and shared configurations
- **`pkgs/`** - Custom packages and overlays
- **`secrets/`** - Encrypted secrets managed with ragenix
### Hosts
- **thor** - AMD desktop system (stable channel)
- **sif** - Intel desktop system (stable channel)
- **odin** - Intel laptop/server hybrid
- **heimdall** - AMD server with self-hosted services
- **baldur** - Intel server with monitoring services
## Features
### System Management
- **flake-parts** for modular flake structure
- **Multi-channel support** (stable/unstable nixpkgs)
- **Hardware-specific configurations** via nixos-hardware
- **Secret management** with ragenix encryption
### Development & Quality
- **Pre-commit hooks** with nix-git-hooks:
- `deadnix` - Remove dead code
- `nixpkgs-fmt` - Format Nix code
- `statix` - Lint for best practices
- `flake-checker` - Validate flake structure
- `mdformat` & `markdownlint` - Markdown formatting
- `typos` - Spell checking
### Home Manager Integration
- **Modular user configurations** in `hm/`
- **Development environments** (cpp, go, javascript, kubernetes)
- **Desktop applications** (alacritty, neovim, browsers)
- **Custom theming** with nix-rice
### Custom Packages
- `keyboard-switch` - Keyboard layout switcher
- `wl-clipedit` - Wayland clipboard editor
- `wl-lockscreen` - Wayland lock screen
- `wl-update-background` - Background updater
## Usage
### Development Environment
```bash
nix develop
```
### Build System
```bash
nix build .#nixosConfigurations.thor.config.system.build.toplevel
```
### Deploy Configuration
```bash
sudo nixos-rebuild switch --flake .#thor
```
### System Images
Generate deployment images:
```bash
nix build .#install-iso # Installer ISO
nix build .#raw-base-image # RAW image
nix build .#vmdk-base-image # VMware image
nix build .#aarch64-base-image # ARM64 image
```
## Configuration Details
### Channels
- **Stable** (`nixpkgs-s`) - Production systems (thor, sif)
- **Unstable** (`nixpkgs-u`) - Development and latest packages
### Modules
- **basic** - Core Nix configuration
- **commonModules** - Shared system modules
- **mainModules** - Desktop environment modules
- **homeManagerModules** - User-level configuration
### Services by Host
- **heimdall**: Nextcloud, Immich, Forgejo, Garage, Ollama
- **baldur**: Vaultwarden, Uptime Kuma, Garage
- **thor/sif**: Steam, Ollama, Garage, Virtualization
- **odin**: IP forwarding, Garage, Steam
## Requirements
- Nix with flakes enabled
- Git for version control
- ragenix for secret management
## Workflow
1. Make changes to configuration
1. Pre-commit hooks automatically validate and format
1. Test with `nix build`
1. Deploy with `nixos-rebuild switch`
1. Commit with validated changes
## License
Personal configuration - not intended for redistribution