Difference between revisions of "Haproxy"
Jump to navigation
Jump to search
(Created page with "``` frontend stats bind *:8404 stats enable # stats uri /stats stats uri /stats stats refresh 10s mode http stats auth admin:admin # stats admi...") |
|||
Line 14: | Line 14: | ||
- http://10.x.x.x:8404/stats | - http://10.x.x.x:8404/stats | ||
- http://10.x.x.x:8404/stats?stats;csv;norefresh | - http://10.x.x.x:8404/stats?stats;csv;norefresh | ||
+ | |||
+ | - https://github.com/bcicen/haproxy-stats | ||
+ | |||
+ | from haproxystats import HAProxyServer | ||
+ | haproxy = HAProxyServer('10.64.4.51:8404/stats') | ||
+ | |||
+ | for b in haproxy.backends: | ||
+ | print('%s: %s' % (b.name, b.status)) |
Revision as of 23:58, 22 March 2020
``` frontend stats
bind *:8404 stats enable # stats uri /stats stats uri /stats stats refresh 10s mode http stats auth admin:admin # stats admin if LOCALHOST # acl network_allowed src 10.x.x.x 1.1.1.1 2.2.2.2 10.0.0.0/8 # stats admin if network_allowed
- http://10.x.x.x:8404/stats
- http://10.x.x.x:8404/stats?stats;csv;norefresh
- https://github.com/bcicen/haproxy-stats
from haproxystats import HAProxyServer haproxy = HAProxyServer('10.64.4.51:8404/stats')
for b in haproxy.backends:
print('%s: %s' % (b.name, b.status))