diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2022-01-05 22:06:03 +0900 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2022-01-06 20:14:35 +0900 |
commit | 155e1bb4e7cf87191007488cf6a68a558a16eca1 (patch) | |
tree | 9a352fe05193b754fdbd48c6e7e6e7ecf0e44bf2 | |
parent | 77b8e92de8264c0b656a7d2fb437dd8d598ab597 (diff) | |
download | systemd-155e1bb4e7cf87191007488cf6a68a558a16eca1.tar.gz |
fstab-generator: also skip other network filesystems and live image
-rw-r--r-- | src/fstab-generator/fstab-generator.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/fstab-generator/fstab-generator.c b/src/fstab-generator/fstab-generator.c index 4b254b087d..9b32383a76 100644 --- a/src/fstab-generator/fstab-generator.c +++ b/src/fstab-generator/fstab-generator.c @@ -769,6 +769,21 @@ static int add_sysroot_mount(void) { return 0; } + if (startswith(arg_root_what, "cifs://")) { + log_debug("Skipping root directory handling, as root on CIFS was requested."); + return 0; + } + + if (startswith(arg_root_what, "iscsi:")) { + log_debug("Skipping root directory handling, as root on iSCSI was requested."); + return 0; + } + + if (startswith(arg_root_what, "live:")) { + log_debug("Skipping root directory handling, as root on live image was requested."); + return 0; + } + if (streq(arg_root_what, "tmpfs")) { /* If root=tmpfs is specified, then take this as shortcut for a writable tmpfs mount as root */ |