diff options
author | Stefan <stefan-guix@vodafonemail.de> | 2020-04-26 21:21:38 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2020-05-02 16:49:30 +0200 |
commit | afc57916e5398737e13d94b3823983783221eb63 (patch) | |
tree | 38d1dbb3ed096b805fadc33a64e84ae980a3d63f | |
parent | 5af2a8fe96e02bd694eae0ee467df25fd4ff1b24 (diff) | |
download | patches-afc57916e5398737e13d94b3823983783221eb63.tar patches-afc57916e5398737e13d94b3823983783221eb63.tar.gz |
linux-boot: Allow the root file system to be mounted via NFS.
* gnu/build/linux-boot.scm (boot-system) Treat a root option with ":/" as an nfs source
and avoid to call 'canonicalize-device-spec' for it.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
-rw-r--r-- | gnu/build/linux-boot.scm | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/gnu/build/linux-boot.scm b/gnu/build/linux-boot.scm index 4fb711b8f2..05e833c0c6 100644 --- a/gnu/build/linux-boot.scm +++ b/gnu/build/linux-boot.scm @@ -534,10 +534,13 @@ upon error." ;; The "--root=SPEC" kernel command-line option always provides a ;; string, but the string can represent a device, a UUID, or a ;; label. So check for all three. - (let ((root (cond ((string-prefix? "/" root) root) - ((uuid root) => identity) - (else (file-system-label root))))) - (mount-root-file-system (canonicalize-device-spec root) + (let ((device-spec (cond ((string-prefix? "/" root) root) + ((uuid root) => identity) + ((string-contains root ":/") #f) ; nfs + (else (file-system-label root))))) + (mount-root-file-system (if device-spec + (canonicalize-device-spec device-spec) + root) root-fs-type #:volatile-root? volatile-root? #:flags root-fs-flags |