/dhcp/status -- give out hostname for UI

This commit is contained in:
Eugene Bujak 2018-12-29 17:04:40 +03:00
parent 86d79ae232
commit 7acb107cbf
1 changed files with 4 additions and 3 deletions

View File

@ -23,6 +23,7 @@ func handleDHCPStatus(w http.ResponseWriter, r *http.Request) {
lease := map[string]string{ lease := map[string]string{
"mac": rawLeases[i].HWAddr.String(), "mac": rawLeases[i].HWAddr.String(),
"ip": rawLeases[i].IP.String(), "ip": rawLeases[i].IP.String(),
"hostname": rawLeases[i].Hostname,
"expires": rawLeases[i].Expiry.Format(time.RFC3339), "expires": rawLeases[i].Expiry.Format(time.RFC3339),
} }
leases = append(leases, lease) leases = append(leases, lease)