Formatter setup to use for the repository.
Home-manager configurations for a combination of host and user.
They are accessed via homeConfigurations.<host>-<user> attributes.
Home-manager modules under theonecfg namespace gated behind enable options.
Modules are grouped in directories by programs, services, or a <user>.
Modules created for one user are not available to another user to enable.
Modules not under a <user> directory are available for all users to define.
See mkUserModules for details about how modules are filtered.
They are accessed via homeConfigurations.<user> attributes.
A nixpkgs package set with theonecfg overlays applied.
NixOS configurations for a host.
They are accessed via nixosConfigurations.<host>.
NixOS modules under theonecfg namespace gated behind enable options.
There is currently little structure here except for user specific modules which are in directories.
Centralized overlays to be used elsewhere in theonecfg.
Pulls in external overlays from inputs.
Pulls in internal overlays from directories in the overlays directory that have a package.nix file.
Currently used in legacy-packages, nixos-modules, and home-configurations.
Packages that can be built or run.
- Get into the root user.
sudo -i
- Wipe all old disk information and check that it looks correct.
wipefs --all /dev/disk/by-id/wwn-0x5000*wipefs --all /dev/disk/by-id/nvme-Samsung_SSD_990_PRO_2TB*lsblk -f
- Clone the repository.
nix-shell -p git neovimgit clone https://github.com/djacu/theonecfg.gitcd theonecfg
- Partition the drives.
This creates a new temporary directory where the drives are mounted.
For example,
/tmp/tmp.kWXrNPDsDG/, which is set toMNTin the setup script.cd nixos-configurations/scheelite./setup.shcd -
- If there have been hardware changes, regenerate the hardware configuration.
Copy it over from
/etcinto the repository and compare the two files.nixos-generate-config --root <MNT>- The generated file will be not be formatted unlike the file in the repository.
In the generated file, swap devices will sometimes get mapped to
/dev/disk/by-uuid. Partition order is fixed, so it is okay to leave them mapped how they are,/dev/xyz. - In the generated file, all file systems, including ZFS pools, will be populated.
If non-legacy mountpoints are used, they should not be included in the
fileSystemsentries. Except for the ones that are required for initrd and those should haveoptions = ["zfsutil"];.1
- Install
sudo nixos-install --no-root-password --flake .#<host> --root <MNT>umount -Rl <MNT>zpool export -a- Make sure to export the pools before reboot or you will see a message like, "The ZFS pool was last accessed by another system.".
If you do forget, the pool can be imported manually after boot with
sudo zpool import -f <pool>. It may take some time for the boot to finish because it will hang on importing a pool unsuccessfully.
- Reboot
home-manager may not be available after bootstrap.
It can be run directly from the repository using nix run.
nix run github:nix-community/home-manager -- switch --flake .#<host>-<user>