in infrajiratext.py [0:0]
def check_ldap(pid):
BASE='ou=project,ou=groups,dc=apache,dc=org'
res = subprocess.run(["ldapsearch", "-x", "-LLL", "-b", BASE, "cn=%s" % pid, "dn"], capture_output=True)
if res.returncode == 0:
if res.stdout != b'':
print("Remove the LDAP project group: %s" % res.stdout.rstrip().decode())
else:
print(res.stderr)