Merge pull request #55 from HBadertscher/disk_ignore_mount
Adds option to ignore mounts via config file
This commit is contained in:
commit
f6dc271839
|
@ -12,7 +12,8 @@
|
|||
},
|
||||
"disk": {
|
||||
"show_tmpfs": false,
|
||||
"show_filesystem": true
|
||||
"show_filesystem": true,
|
||||
"ignore_mounts": []
|
||||
},
|
||||
"ping": {
|
||||
"hosts": [
|
||||
|
|
|
@ -32,6 +32,12 @@ else
|
|||
if (strpos($type, 'tmpfs') !== false && $Config->get('disk:show_tmpfs') === false)
|
||||
continue;
|
||||
|
||||
foreach ($Config->get('disk:ignore_mounts') as $to_ignore)
|
||||
{
|
||||
if ($mount === $to_ignore)
|
||||
continue 2;
|
||||
}
|
||||
|
||||
if (!in_array($mount, $mounted_points))
|
||||
{
|
||||
$mounted_points[] = trim($mount);
|
||||
|
|
Loading…
Reference in New Issue