This is written with the purpose of getting an Ansible inventory from an Active Directory domain controller via LDAP.
- python3
- ldap3
- Run
pip3 install -r requirements.txt
- Copy
ldap-ad.py
andldap-ad.sample.ini
into your/etc/ansible/inventory
folder - Rename
ldap-ad.sample.ini
toldap-ad.ini
and fill in variables
All configuration options are in ldap-ad.ini
and is required for this script to run properly.