diff options
author | antima-gupta <agupta@msystechnologies.com> | 2020-08-28 18:07:41 +0530 |
---|---|---|
committer | antima-gupta <agupta@msystechnologies.com> | 2020-08-28 18:07:41 +0530 |
commit | 4e6234d500475ec772ae2f7d81bfb91067b4a12c (patch) | |
tree | ce5d60b4011beb0ee4f30d852c73a6feb2da02a8 /lib/chef/provider/mount/linux.rb | |
parent | d0764e7849a69f5ce9b0a7bf24a7c0263a9f2c8e (diff) | |
download | chef-4e6234d500475ec772ae2f7d81bfb91067b4a12c.tar.gz |
removed unnecessary 'ostruct' from linux mount provider spec.
Added permalink for Regex.
Renamed the linux_mount recipe file to mount in kitechen-tests.
Signed-off-by: antima-gupta <agupta@msystechnologies.com>
Diffstat (limited to 'lib/chef/provider/mount/linux.rb')
-rw-r--r-- | lib/chef/provider/mount/linux.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/chef/provider/mount/linux.rb b/lib/chef/provider/mount/linux.rb index 919ca118bf..3199024f1b 100644 --- a/lib/chef/provider/mount/linux.rb +++ b/lib/chef/provider/mount/linux.rb @@ -41,12 +41,15 @@ class Chef shell_out!("findmnt -rn").stdout.each_line do |line| case line + # Permalink for device already mounted to mount point for : https://rubular.com/r/L0RNnD4gf2DJGl when /\A#{Regexp.escape(real_mount_point)}\s+#{device_mount_regex}\s/ mounted = true logger.trace("Special device #{device_logstring} mounted as #{real_mount_point}") + # Permalink for multiple devices mounted to the same mount point(i.e. '/proc') https://rubular.com/r/a356yzspU7N9TY when %r{\A#{Regexp.escape(real_mount_point)}\s+([/\w])+\s} mounted = false logger.trace("Special device #{$~[1]} mounted as #{real_mount_point}") + # Permalink for bind device mounted to an existing mount point: https://rubular.com/r/QAE0ilL3sm3Ldz when %r{\A#{Regexp.escape(real_mount_point)}\s+([/\w])+\[#{device_mount_regex}\]\s} mounted = true logger.trace("Bind device #{device_logstring} mounted as #{real_mount_point}") |