diff --git a/templates/server.conf.j2 b/templates/server.conf.j2 index b430164..87f7b9b 100644 --- a/templates/server.conf.j2 +++ b/templates/server.conf.j2 @@ -116,7 +116,11 @@ management-client-user {{ openvpn_management_client_user }} {% if ansible_os_family == 'Debian' %} plugin /usr/lib/openvpn/openvpn-auth-ldap.so "{{ openvpn_base_dir }}/auth/ldap.conf" {% elif ansible_machine == "x86_64" %} +{% if ansible_distribution in ['RedHat','Rocky'] and (ansible_distribution_major_version | int >= 8) %} +plugin /usr/lib64/openvpn/plugins/openvpn-auth-ldap.so "{{ openvpn_base_dir }}/auth/ldap.conf" +{% else %} plugin /usr/lib64/openvpn/plugin/lib/openvpn-auth-ldap.so "{{ openvpn_base_dir }}/auth/ldap.conf" +{% endif %} {% else %} plugin /usr/lib/openvpn/plugin/lib/openvpn-auth-ldap.so "{{ openvpn_base_dir }}/auth/ldap.conf" {% endif %}