2023-06-23 08:12:05 +02:00
|
|
|
{% set username = "rougail_test@silique.fr" %}
|
|
|
|
{% set username_family = "rougail_test@gnunux.info" %}
|
|
|
|
{% set name_family = 'gnunux' %}
|
|
|
|
{% set familydn = ldapclient_base_dn|calc_ldapclient_base_dn(family_name=name_family) %}
|
|
|
|
{% set userdn = 'cn=' + username + ',' + ldapclient_base_dn|calc_ldapclient_base_dn %}
|
|
|
|
{% set userfamilydn = 'cn=' + username_family + ',' + familydn %}
|
|
|
|
address: {{ general.network.ip_eth0 }}
|
|
|
|
admin_dn: {{ ldapclient_user }}
|
|
|
|
admin_password: {{ general.ldap.client.ldapclient_user_password }}
|
|
|
|
user_dn: {{ userdn }}
|
|
|
|
user_password: {{ username|get_password(server_name='test', description='test', type="cleartext", hide=hide_secret, temporary=True) }}
|
|
|
|
user_family_dn: {{ userfamilydn }}
|
|
|
|
user_family_password: {{ username_family|get_password(server_name='test', description="test", type="cleartext", hide=hide_secret, temporary=True)
|
|
|
|
base_account_dn: {{ ldap_account_dn }}
|
|
|
|
base_user_dn: {{ ldapclient_user_dn }}
|
|
|
|
base_family_dn: {{ familydn }}
|
|
|
|
base_group_dn: {{ ldapclient_group_dn }}
|
|
|
|
{% for idx in range(3) %}
|
|
|
|
{% set name = 'remote_test' + idx|string %}
|
|
|
|
remote{{ idx }}: cn={{ name }},{{ ldapclient_base_dn }}
|
|
|
|
remote_password{{ idx }}: {{ name|get_password(server_name=domain_name_eth0, description="remote account", type="cleartext", hide=hide_secret, temporary=True) }}
|
|
|
|
{% endfor %}
|
2022-07-07 09:37:49 +02:00
|
|
|
users:
|
2023-06-23 08:12:05 +02:00
|
|
|
{{ username }}: {{ userdn }}
|
|
|
|
{{ username_family }}: {{ userfamilydn }}
|
|
|
|
{% for user in accounts.users.ldap_user_mail %}
|
|
|
|
{{ user }}: cn={{ user }},{{ ldapclient_user_dn }}
|
|
|
|
{% endfor %}
|
|
|
|
{% for family in accounts.families %}
|
|
|
|
{% set families = ldapclient_base_dn|calc_ldapclient_base_dn(family) %}
|
|
|
|
{% for user in accounts['family_' + family]['users_' + family]['ldap_user_mail_' + family] %}
|
|
|
|
{{ user }}: cn={{ user }},{{ families }}
|
|
|
|
{% endfor %}
|
|
|
|
{% endfor %}
|
2022-07-07 09:37:49 +02:00
|
|
|
groups:
|
|
|
|
users:
|
2023-06-23 08:12:05 +02:00
|
|
|
- {{ userdn }}
|
|
|
|
{% for user in accounts.users.ldap_user_mail %}
|
|
|
|
- cn={{ user }},{{ ldapclient_user_dn }}
|
|
|
|
{% endfor %}
|
|
|
|
{% for family in accounts.families
|
|
|
|
{{ family }}:
|
|
|
|
{% if family == name_family }
|
|
|
|
- {{ userfamilydn }}
|
|
|
|
{% endif %}
|
|
|
|
{% for user in accounts['family_' + family]['users_' + family]['ldap_user_mail_' + family] %}
|
|
|
|
- cn={{ user }},{{ families }}
|
2022-07-07 09:37:49 +02:00
|
|
|
%end for
|
|
|
|
%end for
|
2023-06-23 08:12:05 +02:00
|
|
|
{% if 'gnunux' not in accounts.families %}
|
|
|
|
{% set families = ldapclient_base_dn|calc_ldapclient_base_dn('gnunux') %}
|
2023-01-17 21:43:32 +01:00
|
|
|
gnunux:
|
2023-06-23 08:12:05 +02:00
|
|
|
- cn=rougail_test@gnunux.info,{{ families }}
|
2023-01-17 21:43:32 +01:00
|
|
|
%end if
|