diff options
author | Lance Albertson <lance@osuosl.org> | 2021-02-12 11:06:56 -0800 |
---|---|---|
committer | Lance Albertson <lance@osuosl.org> | 2021-02-12 11:10:14 -0800 |
commit | 3ca53d4c6d412a6cc11892357867889e0f5ac89b (patch) | |
tree | 2c77d8e36a8872364284726de3d58034b5791638 /spec | |
parent | 4cfb8455fcc4ffcb452c43666b0f02c140d94d82 (diff) | |
download | chef-3ca53d4c6d412a6cc11892357867889e0f5ac89b.tar.gz |
Fix network mounts which use the root level as the device
PR #10614 introduce a bug which can impact network mounts which try to mount
from the root level (i.e. server:/). Specifically, we run into this on cephfs
where this is pretty common. This adds some logic to detect if this is a network
mount at the root level and doesn't strip the '/'.
This resolves #10764.
Signed-off-by: Lance Albertson <lance@osuosl.org>
Diffstat (limited to 'spec')
-rw-r--r-- | spec/unit/provider/mount/mount_spec.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/spec/unit/provider/mount/mount_spec.rb b/spec/unit/provider/mount/mount_spec.rb index 9a7d9198b5..015e0038c8 100644 --- a/spec/unit/provider/mount/mount_spec.rb +++ b/spec/unit/provider/mount/mount_spec.rb @@ -66,6 +66,7 @@ describe Chef::Provider::Mount::Mount do describe "when dealing with network mounts" do { "nfs" => "nfsserver:/vol/path", + "cephfs" => "cephserver:6789:/", "cifs" => "//cifsserver/share" }.each do |type, fs_spec| it "should detect network fs_spec (#{type})" do @new_resource.device fs_spec |