fixed errors

This commit is contained in:
Daniel Barbero Martin 2019-11-13 17:50:22 +01:00
parent 8645b01828
commit 42fc81a408

View File

@ -676,6 +676,13 @@ class Diagnostics extends Wizard
$cpuProcessor = 'cat /proc/cpuinfo | grep "processor" | wc -l'; $cpuProcessor = 'cat /proc/cpuinfo | grep "processor" | wc -l';
$ramMemTotal = 'cat /proc/meminfo | grep "MemTotal"'; $ramMemTotal = 'cat /proc/meminfo | grep "MemTotal"';
exec(
"ifconfig | awk '{ print $2}' | grep -E -o '([0-9]{1,3}[\.]){3}[0-9]{1,3}'",
$output
);
$ips = implode(', ', $output);
$result = [ $result = [
'error' => false, 'error' => false,
'data' => [ 'data' => [
@ -697,9 +704,7 @@ class Diagnostics extends Wizard
], ],
'ipInfo' => [ 'ipInfo' => [
'name' => __('Ip'), 'name' => __('Ip'),
'value' => exec( 'value' => $ips,
"/sbin/ifconfig eth0 | grep 'inet addr' | cut -d: -f2 | awk '{print $1}'"
),
], ],
], ],
]; ];