basant/basant/raw/nixOS.wiki

52 lines
2.2 KiB
Plaintext

[[nixpkgs]]
[[nix-lang]]
= basics =
nix is a functional, immutable package manager
nix (the package manager) is written in the nix language
nixOS is a linux distribution built on top of the nix package manager
in nixOS there are 2 kinds of packages. Regular packages and modules which do the configuration management of said packages. Both of these are written in the nix language. Even on nixOS configuration files generally cannot be set through the package manager. Insead [home-manager](https://github.com/nix-community/home-manager ) can be used.
= installing nix package manager =
curl -o install-nix https://nixos.org/nix/install
curl -o install-nix.asc https://releases.nixos.org/nix/nix-2.3.7/install.asc
gpg2 --recv-keys B541D55301270E0BCF15CA5D8170B4726D7198DE
gpg2 --verify ./install-nix.asc
sh ./install-nix
rm ./install-nix.asc ./install-nix
= nix-isms =
dev environments:
generally the right way to define dev environments is through a shell.nix file which gets invoked when calling nix-shell
in this file we define which packages we expect in order to build and run the program
= build options =
in NixOS it often feels like the options are the magic part of building software. everyone seems to have just the right options in order to build the software they need
however, fear not, you too can be a master of options by searching at:
https://search.nixos.org/options or `nixos-option`
= install the OS =
https://gist.github.com/ladinu/bfebdd90a5afd45dec811296016b2a3f
have to use LUKS1 (grub2 doesn't support luks2 -> should be available by grub2.06)
= Generated Tags =
== nix ==
- [[vim2nix|vim2nix]]
- [[Punya|Punya]]
- [[210416-2252|mach-nix and reproducible Python builds]]
- [[210124-0140|Updating Curve]]
- [[210103-2319|Matrix Bridges]]
- [[201129-2055|Getting Matrix Online]]
- [[201121-1417|Shaarli Setup]]
- [[201119-1157|Ops tasks for bowl]]
- [[201118-1522|Getting Web-Services to run on NixOS]]
- [[201118-1520|201118-1520]]
- [[201108-2359|What I learnt switching bowl to NixOS]]
- [[201020-1926|Amazed at the NixOS Community]]
- [[201019-2038|Alert when nixpkgs unstable is unavailable]]
- [[201019-1905|NixOS Quick Tips]]