change from mono-home-manager to full flake multi-system configuration
This commit is contained in:
68
README.md
Normal file
68
README.md
Normal file
@@ -0,0 +1,68 @@
|
||||
# nixConfig
|
||||
This is a modular, flake-based Nix configuration repository for managing all personal machines and environments in one place. It supports:
|
||||
- Full system configuration for NixOS laptop.
|
||||
- Home Manager user environments on all machines (NixOS, Ubuntu, WSL, servers).
|
||||
- Reusable modules for programs and services.
|
||||
- Declarative configuration and reproducible builds.
|
||||
|
||||
## Repository Structure
|
||||
|
||||
```shell
|
||||
nixConfig/
|
||||
├── flake.nix # Flake entry point with all system and user configs
|
||||
├── flake.lock # Input versions for reproducibility
|
||||
├── hosts/ # Per-host system-level configs
|
||||
│ ├── t440p # NixOS system config for laptop
|
||||
│ │ ├── configuration.nix # NixOS system config
|
||||
│ │ └── hardware-configuration.nix # Hardware config generated by NixOS
|
||||
│ ├── steamdeck # NixOS system running on Valve Steamdeck
|
||||
│ ├── xaorus # home-manager on Ubuntu
|
||||
│ └── vps04_08 # services running on Ubuntu VPS
|
||||
├── home/ # Home Manager configs (user environments)
|
||||
│ └── home.nix # Shared user config for 'wieerwill'
|
||||
├── modules/ # Shared program/service modules
|
||||
│ └── ...
|
||||
```
|
||||
|
||||
## Usage
|
||||
### Rebuild the system
|
||||
use the systems name at the end. Example:
|
||||
```bash
|
||||
sudo nixos-rebuild switch --flake ~/nixConfig#t440p
|
||||
```
|
||||
|
||||
### Rebuild Home Manager only (e.g. on non-NixOS systems)
|
||||
```bash
|
||||
home-manager switch --flake ~/nixConfig#<username>@<hostname>
|
||||
```
|
||||
|
||||
### Update flake inputs
|
||||
```bash
|
||||
nix flake update
|
||||
```
|
||||
or use the scripts in `/scripts`. The script is build for on-system execution and will clean up afterwards:
|
||||
```bash
|
||||
chmod +x ./scripts/nix-maintain.sh
|
||||
./scripts/nix-maintain.sh
|
||||
```
|
||||
|
||||
## Setup
|
||||
|
||||
* `/etc/nixos` is a symlink to `~/nixConfig` so NixOS can find configuration files (`sudo ln -s /home/$USER/nixConfig /etc/nixos`).
|
||||
* Uses matching Home Manager and Nixpkgs versions (`release-25.05`) to avoid compatibility warnings.
|
||||
* Home Manager is integrated via NixOS modules for system-wide user config.
|
||||
|
||||
## Modules
|
||||
|
||||
The `home/` and `modules/` directory will contain reusable modules such as:
|
||||
* `neovim.nix` – editor configuration
|
||||
* `firefox.nix` – browser preferences
|
||||
* `git.nix` – shared Git settings
|
||||
* `traefik.nix` – server services
|
||||
|
||||
These modules will be selectively included in each host config or enabled conditionally.
|
||||
|
||||
## Secrets & Private Data
|
||||
|
||||
Do **not** store secrets or passwords in this repository!
|
||||
SOPS with age is provided in the configuration as secure method for secrets management.
|
||||
Reference in New Issue
Block a user