feat: Wrote README improving folder structure otw
This commit is contained in:
parent
bb50ea0d5a
commit
5835335a2e
66
README.md
66
README.md
|
@ -1,5 +1,65 @@
|
|||
# Meine wundervolle nix config
|
||||
|
||||
For secrets:
|
||||
- encrypt using: `rage -R recipients.txt -o [OUT] -e [IN] `
|
||||
- decrypt using: `rage -R recipients.txt -o [OUT] -d [IN] `
|
||||
## Structure
|
||||
|
||||
- `hosts/` contain nixos configuration for hosts
|
||||
- `common/` shared configuration modules
|
||||
- `core/` base configuration shared on all machines
|
||||
- `dev/` configuration enabling dev environment
|
||||
- `graphical/` configuration for graphical environments
|
||||
- `hardware/` configuration for hardware components
|
||||
- `<hostname>/` configuration for hosts
|
||||
- `default.nix` Toplevel system definition
|
||||
- `fs.nix` file system definiton
|
||||
- `net.nix` network setup
|
||||
- `secrets/` secrets local to this hosts
|
||||
- `secrets.nix.age` local secrets usable on deploy
|
||||
- `host.pub` host public key, needed for rekeying agenix secrets
|
||||
- `modules/` extra nixos modules
|
||||
- `secrets.nix` module to enable deploy-time secrets
|
||||
- `nix/` additional nix functions
|
||||
- `checks.nix` pre-commit checks
|
||||
- `colmena.nix` Setup for using colmena to deploy
|
||||
- `devshell.nix` Development shell
|
||||
- `extra-builtins.nix` Extra builtin plugin file to enable repository secrets
|
||||
- `generate-node.nix` logic to generate nodes for colmena
|
||||
- `lib.nix` additional library functions
|
||||
- `secrets/` global secrets
|
||||
- `<name>.key.pub` public key handles to decrypt secrets using yubikey
|
||||
- `recipients.txt` rage recipient file for encrypting secrets
|
||||
- currently containing both yubikeys and a rage backup key
|
||||
- `secrets.nix.age` global secrets available at deploy
|
||||
- `users/` home manager user configuration
|
||||
- `common/` shared home-manager modules
|
||||
- `graphical/` configuration for graphical programs
|
||||
- `programs/` configuration for miscellaneous programs
|
||||
- `shells/` configuration for shells
|
||||
- `impermanence.nix` hm-impermanence setup for users
|
||||
- `default.nix` minimal setup for all users
|
||||
- `interactive.nix` minimal setup for interactive users on a command line
|
||||
- `graphical.nix` configuration for users utilizing a graphical interface
|
||||
- `<username>/` configuration for users
|
||||
- `impermanence.nix` users persistence configuration
|
||||
|
||||
## Hosts
|
||||
- `patricknix` my main laptop
|
||||
|
||||
## Users
|
||||
- `patrick` my normal everyday unprivileged user
|
||||
- `root` root user imported by every host
|
||||
|
||||
## Flake structure
|
||||
|
||||
## How-To
|
||||
|
||||
...TODO
|
||||
|
||||
## Deploy
|
||||
|
||||
```bash
|
||||
colmena apply --on <hostname>
|
||||
```
|
||||
If deploying from a host not containing the necessary nix configuration option append
|
||||
```bash
|
||||
--nix-option plugin-files "$NIX_PLUGINS"/lib/nix/plugins --nix-option extra-builtins-file ./nix/extra-builtins`
|
||||
```
|
||||
|
|
|
@ -102,7 +102,7 @@
|
|||
};
|
||||
apps = agenix-rekey.defineApps self pkgs self.nodes;
|
||||
checks = import ./nix/checks.nix inputs system;
|
||||
devShell = import ./nix/dev-shell.nix inputs system;
|
||||
devShell = import ./nix/devshell.nix inputs system;
|
||||
formatter = pkgs.alejandra;
|
||||
});
|
||||
}
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
{
|
||||
imports = [
|
||||
./efi.nix
|
||||
./home-manager.nix
|
||||
./impermanence.nix
|
||||
./inputrc.nix
|
||||
./issue.nix
|
||||
./net.nix
|
||||
|
@ -7,8 +10,6 @@
|
|||
./ssh.nix
|
||||
./system.nix
|
||||
./xdg.nix
|
||||
./impermanence.nix
|
||||
./home-manager.nix
|
||||
|
||||
../../../users/root
|
||||
|
||||
|
|
|
@ -1,5 +0,0 @@
|
|||
{
|
||||
imports = [
|
||||
./fonts.nix
|
||||
];
|
||||
}
|
|
@ -7,19 +7,20 @@
|
|||
|
||||
../common/core
|
||||
../common/dev
|
||||
../common/graphical
|
||||
|
||||
../common/graphical/fonts.nix
|
||||
../common/graphical/steam.nix
|
||||
|
||||
../common/hardware/bluetooth.nix
|
||||
../common/hardware/intel.nix
|
||||
../common/hardware/laptop.nix
|
||||
../common/hardware/physical.nix
|
||||
../common/efi.nix
|
||||
../common/laptop.nix
|
||||
../common/pipewire.nix
|
||||
../common/steam.nix
|
||||
../common/yubikey.nix
|
||||
../common/zfs.nix
|
||||
../common/hardware/pipewire.nix
|
||||
../common/hardware/yubikey.nix
|
||||
../common/hardware/zfs.nix
|
||||
|
||||
../common/hardware/nvidia.nix
|
||||
./prime-offload.nix
|
||||
../common/hardware/prime-offload.nix
|
||||
|
||||
./net.nix
|
||||
./fs.nix
|
||||
|
|
|
@ -1,23 +0,0 @@
|
|||
{
|
||||
description = "Patrick tolles flake template";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
};
|
||||
|
||||
outputs = {
|
||||
self,
|
||||
nixpkgs,
|
||||
flake-utils,
|
||||
}:
|
||||
flake-utils.lib.eachDefaultSystem (system: let
|
||||
pkgs = import nixpkgs {inherit system;};
|
||||
in {
|
||||
devShells.default = pkgs.mkShell {
|
||||
packages = with pkgs; [
|
||||
st
|
||||
];
|
||||
};
|
||||
});
|
||||
}
|
|
@ -1,12 +0,0 @@
|
|||
{
|
||||
description = "A collection of flake templates";
|
||||
|
||||
outputs = {self}: {
|
||||
templates = {
|
||||
default = {
|
||||
path = ./default;
|
||||
description = "My own basic flake template";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -27,6 +27,8 @@
|
|||
home-manager.users.patrick = {
|
||||
imports = [
|
||||
./patrick.nix
|
||||
./ssh.nix
|
||||
./impermanence.nix
|
||||
../common
|
||||
../common/interactive.nix
|
||||
../common/graphical.nix
|
||||
|
|
18
users/patrick/impermanence.nix
Normal file
18
users/patrick/impermanence.nix
Normal file
|
@ -0,0 +1,18 @@
|
|||
{
|
||||
config,
|
||||
extraLib,
|
||||
...
|
||||
}: {
|
||||
home = {
|
||||
persistence."/state/${config.home.homeDirectory}" = {
|
||||
allowOther = true;
|
||||
directories = extraLib.impermanence.makeSymlinks [
|
||||
"repos"
|
||||
"Downloads"
|
||||
|
||||
"./Nextcloud"
|
||||
".config/Nextcloud"
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,26 +1,7 @@
|
|||
{
|
||||
pkgs,
|
||||
config,
|
||||
extraLib,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
./ssh.nix
|
||||
];
|
||||
|
||||
{pkgs, ...}: {
|
||||
home = {
|
||||
packages = [
|
||||
pkgs.nextcloud-client
|
||||
];
|
||||
persistence."/state/${config.home.homeDirectory}" = {
|
||||
allowOther = true;
|
||||
directories = extraLib.impermanence.makeSymlinks [
|
||||
"repos"
|
||||
"Downloads"
|
||||
|
||||
"./Nextcloud"
|
||||
".config/Nextcloud"
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue