ansible-roles/gcube/authorization_service/templates/AuthorizationConfiguration....

27 lines
894 B
Django/Jinja

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Configuration>
<Rule path="/token/user" requiresToken="false">
{% for ip in authorized_ips %}
<Entity type="IP" value="{{ ip }}" />
{% endfor %}
</Rule>
<Rule path="/apikey" requiresToken="true" acceptedTokenTypes="USER"/>
<Rule path="/policyManager" requiresToken="true">
{% for ip in authorized_ips %}
<Entity type="IP" value="{{ ip }}" />
{% endfor %}
</Rule>
<Rule path="/token/external" requiresToken="true" acceptedTokenTypes="USER" />
<Rule path="/token/node" requiresToken="false" />
<Rule path="/token/service" requiresToken="true" acceptedTokenTypes="CONTAINER"/>
<Rule path="/token/resolve" requiresToken="false">
{% if authorized_ips is defined %}
{% for ip in authorized_ips %}
<Entity type="IP" value="{{ ip }}" />
{% endfor %}
{% endif %}
</Rule>
</Configuration>