Open cbeaujoin-stellar opened 1 month ago
Allow multiple openwisp2_admin_allowed_network in nginx site-conf.j2 template
openwisp2_admin_allowed_network
https://github.com/openwisp/ansible-openwisp2/blob/dcdcd21aa59c38a401cd7bcdb1adfbf24de1ffbe/templates/nginx/site-conf.j2#L68
{% if openwisp2_admin_allowed_network %} location /admin/ { try_files {{ openwisp2_path }}/public_html/maintenance.html $uri @uwsgi; {% for network in openwisp2_admin_allowed_network %} allow {{ network }}; {% endfor %} deny all; } {% endif %}
https://github.com/openwisp/ansible-openwisp2/blob/dcdcd21aa59c38a401cd7bcdb1adfbf24de1ffbe/defaults/main.yml#L68
openwisp2_admin_allowed_network: []
IE:
openwisp2_admin_allowed_network: - "192.168.1.0/24" - "10.0.0.1"
Allow multiple
openwisp2_admin_allowed_network
in nginx site-conf.j2 templatehttps://github.com/openwisp/ansible-openwisp2/blob/dcdcd21aa59c38a401cd7bcdb1adfbf24de1ffbe/templates/nginx/site-conf.j2#L68
https://github.com/openwisp/ansible-openwisp2/blob/dcdcd21aa59c38a401cd7bcdb1adfbf24de1ffbe/defaults/main.yml#L68
IE: