Depending on the Scale, I'd personally go with an own Kaiwa Fork, backed by an Erlang MongooseIM Backend and LDAP.