# Pass a file with `-f`. Use `-Y EXTERNAL` for server configs. ldapmodify -H ldapi:/// -Y EXTERNAL -f change.ldif # Or bind using an admin account with `-W -D ` ldapmodify -H ldapi:/// -f change.ldif -D cn=admin,dc=devdungeon,dc=com -W # Pass the ldif directly ldapmodify -H ldapi:/// -Y EXTERNAL << EOF dn: cn=config changetype: modify replace: olcTLSCertificateFile olcTLSCertificateFile: /etc/letsencrypt/live/ldap.devdungeon.com/cert.pem - replace: olcTLSCertificateKeyFile olcTLSCertificateKeyFile: /etc/letsencrypt/live/ldap.devdungeon.com/privkey.pem EOF