1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-23 06:01:15 +00:00
nixpkgs/nixos
Bjørn Forsman 581226cfb4 nixos/bcache: /bin/sh -> ${bash}/bin/sh
Or else `services.udev.packages = [ bcache-tools ]` cannot be used.

To not break bcache in the initrd I'm modifying this in stage-1.nix:

  -  --replace /bin/sh ${extraUtils}/bin/sh
  +  --replace ${bash}/bin/sh ${extraUtils}/bin/sh

Reasoning behind that change:

* If not modifying the /bin/sh pattern in any way, it will also match
  ${bash}/bin/sh, creating a broken path like
  /nix/store/HASH-bash/nix/store/HASH-bash/bin/sh in the udev rule file.

* The addition of /bin/sh was done in 775f381a9e
  ("stage-1: add bcache support"). It seems somewhat plausible that
  no new users have appeared since then and we can take this opportunity
  to back out of this change without much fear of regressions.

  If there _are_ regressions, they should be in the form of build time
  errors, not runtime (boot), due to how the udev rule output is checked
  for invalid path references. So low risk, IMHO.

* An alternative approach could be to copy the /bin/sh substitute rule
  over to the non-initrd udev rules implementation in NixOS, but I think
  this way is better:
  - The rules file comes with a working path out of the box.
  - We can use more precise pattern matching when modifying the udev
    rules for the initrd.
2017-06-10 17:10:49 +02:00
..
doc/manual doc: clarify building-nixos CD/DVD instructions 2017-06-02 21:13:19 -04:00
lib NixOS VM tests: Don't create a setgid group in vde_switch 2017-06-07 11:57:36 +02:00
maintainers make-disk-image: change to be less VM-centric 2017-04-24 02:30:00 +00:00
modules nixos/bcache: /bin/sh -> ${bash}/bin/sh 2017-06-10 17:10:49 +02:00
tests Merge pull request #23173 from nlewo/test/cloudinit 2017-06-05 18:34:06 -04:00
COPYING
default.nix Remove nixFallback 2017-03-06 15:54:50 +01:00
README
release-combined.nix nixos: Add a VM test for the SLiM display manager 2017-04-23 19:25:27 +02:00
release-small.nix nixos/release-small.nix: cleanup to use default versions 2017-01-27 15:33:54 +01:00
release.nix Merge pull request #23173 from nlewo/test/cloudinit 2017-06-05 18:34:06 -04:00

*** NixOS ***

NixOS is a Linux distribution based on the purely functional package
management system Nix.  More information can be found at
http://nixos.org/nixos and in the manual in doc/manual.