diff options
Diffstat (limited to 'configuration')
| -rw-r--r-- | configuration/busybox.nix | 4 | ||||
| -rw-r--r-- | configuration/default.nix | 19 | ||||
| -rw-r--r-- | configuration/minimal.nix | 9 | ||||
| -rw-r--r-- | configuration/module-fixes.nix | 18 |
4 files changed, 50 insertions, 0 deletions
diff --git a/configuration/busybox.nix b/configuration/busybox.nix new file mode 100644 index 0000000..d9135eb --- /dev/null +++ b/configuration/busybox.nix @@ -0,0 +1,4 @@ +{ pkgs, ... }: +{ + environment.systemPackages = [ pkgs.busybox ]; +} diff --git a/configuration/default.nix b/configuration/default.nix new file mode 100644 index 0000000..1a5b2da --- /dev/null +++ b/configuration/default.nix @@ -0,0 +1,19 @@ +{ + imports = [ + ./busybox.nix + ./minimal.nix # Making this configuration a bit smaller to save on build time & download size + ./module-fixes.nix # Module-level fixes for musl + ]; + + boot.loader.systemd-boot.enable = true; + + fileSystems = { + "/" = { + device = "none"; + fsType = "ramfs"; + }; + }; + + # You probably know the drill. Don't change this. + system.stateVersion = "24.11"; +} diff --git a/configuration/minimal.nix b/configuration/minimal.nix new file mode 100644 index 0000000..ff0ebc2 --- /dev/null +++ b/configuration/minimal.nix @@ -0,0 +1,9 @@ +{ modulesPath, ... }: +{ + imports = [ + # The configuration is mainly for testing. We don't need to actually use much + (modulesPath + "/profiles/minimal.nix") + # This includes perl + (modulesPath + "/profiles/perlless.nix") + ]; +} diff --git a/configuration/module-fixes.nix b/configuration/module-fixes.nix new file mode 100644 index 0000000..ee3005c --- /dev/null +++ b/configuration/module-fixes.nix @@ -0,0 +1,18 @@ +{ pkgs, ... }: +{ + environment = { + # NOTE: This is what prints the fun error message about + # binaries not compiled for NixOS not working with it + # + # It's here because on x86_64 systems, a 32-bit `ld` stub + # is built against `pkgs.pkgsi686Linux`; nixpkgs doesn't + # support a pure i686 musl bootstrap, so it throws an eval + # error. womp womp + stub-ld.enable = false; + }; + + # HACK: nixpkgs instantiated for musl doesn't have glibc locales, so the + # default value throws eval errors + # This will probably break something + i18n.glibcLocales = pkgs.emptyFile; +} |
