mirror of
https://github.com/webmin/webmin.git
synced 2026-03-20 16:50:24 +00:00
Show IP next to hostname
This commit is contained in:
@@ -33,9 +33,16 @@ if ($level == 0) {
|
||||
# Show general system information
|
||||
print "<table width=70%>\n";
|
||||
|
||||
# Ask status module for collected info
|
||||
&foreign_require("system-status");
|
||||
$info = &system_status::get_collected_info();
|
||||
|
||||
# Hostname
|
||||
$ip = $info && $info->{'ips'} ? $info->{'ips'}->[0]->[0] :
|
||||
&to_ipaddress(get_system_hostname());
|
||||
$ip = " ($ip)" if ($ip);
|
||||
print "<tr> <td><b>$text{'right_host'}</b></td>\n";
|
||||
print "<td>",&get_system_hostname(),"</td> </tr>\n";
|
||||
print "<td>",&get_system_hostname(),$ip,"</td> </tr>\n";
|
||||
|
||||
# Operating system
|
||||
print "<tr> <td><b>$text{'right_os'}</b></td>\n";
|
||||
@@ -58,10 +65,6 @@ if ($level == 0) {
|
||||
}
|
||||
print "<td>$tm</td> </tr>\n";
|
||||
|
||||
# Ask status module for more
|
||||
&foreign_require("system-status");
|
||||
$info = &system_status::get_collected_info();
|
||||
|
||||
# Kernel and CPU
|
||||
if ($info->{'kernel'}) {
|
||||
print "<tr> <td><b>$text{'right_kernel'}</b></td>\n";
|
||||
|
||||
Reference in New Issue
Block a user