diff options
Diffstat (limited to '')
| -rw-r--r-- | content/theses/self-sufficiency/setup-nixos.md | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/content/theses/self-sufficiency/setup-nixos.md b/content/theses/self-sufficiency/setup-nixos.md new file mode 100644 index 0000000..5eeb0b9 --- /dev/null +++ b/content/theses/self-sufficiency/setup-nixos.md @@ -0,0 +1,36 @@ +--- +title: setup nixos +weight: 5 +--- +{{% hint info %}} +This is ***not*** intended to be a NixOS configuration guide. +For berevity, I assume you have a fresh NixOS installation. +To learn Nix and NixOS, [read this guide](https://nixos-and-flakes.thiscute.world/). +{{% /hint %}} + +{{% hint warning %}} +This guide is flake agnostic. +I use flakes for my personal setup, but everything in the [self-sufficiency notes](/theses/self-sufficiency/intro-nixos) uses classic modules. +You can find my setup [here](https://code.aethrvmn.gr/configs/nix.git). +{{% /hint %}} + +With a fresh NixOS installation, the `configuration.nix` should be in `/etc/nixos/`. Inside that directory, we can make a folder `modules` +```sh +$ mkdir modules +``` +and make a file `default.nix` inside that folder. +```sh +$ touch modules/default.nix +``` +then we can just add that to our `configuration.nix` +```nix +# /etc/nixos/configuration.nix +#... +imports = [ + #... + ./modules + #... +]; +#... +``` +Inside this `modules/` folder is where we will write all the services. |
