Skip to content

iamlyth/nixos

Repository files navigation

NixOS Configuration

This repository contains a complete, declarative NixOS configuration suite managed via Nix Flakes. It provides tailored system and user configurations for multiple hardware targets and usage scenarios.

📂 Repository Structure

  • /hosts: Machine-specific system configurations.
  • /home-manager: User-level configurations (dotfiles, user apps).
  • /modules: Shared system modules (e.g., Plex, Immich, Sway).
  • /containers: LXC templates and specific container configs.

🛠️ Bootstrapping on a Fresh Install

1. Enable Flakes

By default, NixOS does not have Flakes enabled. You must first add the following to your /etc/nixos/configuration.nix:

nix shell nixpkgs#git --extra-experimental-features "nix-command flakes"

2. Clone this Repository

Clone this repo to your desired location (e.g., ~/nixos-config):

git clone https://github.com/iamlyth/nixos.git
cd ~/nixos

3. Apply the Flake Configuration

Once in the directory, you can switch your system to one of the predefined host configurations:

sudo nixos-rebuild switch --flake .#<hostname>

(Replace <hostname> with desktopOS, laptopOS, mediaOS, etc.)

🚀 Usage

Applying a Configuration

To apply a configuration to your current system, ensure you have Nix Flakes enabled and run:

sudo nixos-rebuild switch --flake .#<hostname>

Example for desktop:

sudo nixos-rebuild switch --flake .#desktopOS

Building the LXC Template

To generate a Proxmox LXC template image:

nix build .#lxctemplate

About

This is my personal NixOS repository. Publicly availble for anyone to borrow ideas from or clone for themselves. Featuring configurations for my Desktop, laptop, homelab (both virtual machines and LXCs), wsl for work, and single board computers.

Topics

Resources

Stars

Watchers

Forks

Contributors

Languages