ansible-openwisp2
ansible-openwisp2 copied to clipboard
[feature] Enable nginx_status
In order to monitor nginx, it would be great to be able to enable Nginx status module in the site-conf.j2 template.
{% if openwisp2_nginx_status%}
location = /nginx_status {
stub_status;
allow 127.0.0.1; # only allow requests from localhost
deny all; # deny all other hosts
}
{% endif %}
Enable with (false by default):
openwisp2_nginx_status: true
Wouldn't sending a request to /static/staticfiles.json allow you to obtain the same goal without the need of these extra lines of code?
It may provide same information but is less seamless to integrate with metricbeats nginx module: https://www.elastic.co/docs/reference/beats/metricbeat/metricbeat-module-nginx