Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Tools
NetData Trafficlight
Commits
c0f210eb
Commit
c0f210eb
authored
Sep 03, 2018
by
Jürgen Haas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change requests to use ip address and not hostname to avoid millions of local dns requests
parent
3e5fed25
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
netdata.py
netdata.py
+3
-1
No files found.
netdata.py
View file @
c0f210eb
...
...
@@ -10,6 +10,7 @@ import datetime
import
json
import
os
import
requests
import
socket
import
threading
import
time
import
types
...
...
@@ -76,6 +77,7 @@ class Host:
self
.
latest_change
=
0
self
.
alarms
=
{}
self
.
widget
=
None
self
.
ip
=
socket
.
gethostbyname
(
self
.
hostname
)
self
.
_queue
(
'new host'
)
def
watch
(
self
):
...
...
@@ -138,7 +140,7 @@ class Host:
@
property
def
url
(
self
):
# type: () -> basestring
return
'http://%s:19999'
%
self
.
hostname
return
'http://%s:19999'
%
self
.
ip
@
property
def
fullname
(
self
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment