assignment: added section (roughly) on nixos

This commit is contained in:
silver 2024-10-16 20:04:42 +01:00
parent e749191a47
commit 741bd1d948
Signed by: silver
GPG key ID: 36F93D61BAD3FD7D
2 changed files with 21 additions and 3 deletions

BIN
_git.tar.gz (Stored with Git LFS)

Binary file not shown.

View file

@ -99,6 +99,23 @@ This is also the format that we use in Skynet.
The [Official Wiki Page][nix_flake] will be more informative than what can be shoved into this article.
### Nixos
With teh package manager we are able to create packages in a deterministic manner and store them in a way that does not suffer path conflicts.
Some (possibly crazy) folks saw this and decided to apply this to an entire operating system.
The advantages are clear, the required programs are added to teh path for teh current iteration of the system.
If any error arises the system can be rolled back to a previous config.
Configuration is done via ``*.nix`` files, which are then converted into teh native config for the application in question.
For example [this file][nix_dns] turns a list of attributes.
```nix
{
record = "forgejo";
r_type = "CNAME";
value = "glados.skynet.ie";
}
```
Into a config usable by the BIND DNS server.
### Lix
@ -128,4 +145,5 @@ The [Official Wiki Page][nix_flake] will be more informative than what can be sh
[nix_guide_official]: https://nix.dev/tutorials/first-steps/
[nix_guide_pills]: https://nixos.org/guides/nix-pills/#
[nix_pkgs_sieve]: https://github.com/NixOS/nixpkgs/blob/a3c0b3b21515f74fd2665903d4ce6bc4dc81c77c/pkgs/by-name/si/sieve-editor-gui/package.nix
[nix_flake]: https://wiki.nixos.org/wiki/Flakes
[nix_flake]: https://wiki.nixos.org/wiki/Flakes
[nix_dns]: https://forgejo.skynet.ie/Skynet/nixos/src/branch/main/applications/dns/dns.nix