Ruby one-liner to retrieve user groups from Atlassian Crowd

As you may guess from the title that my previous method did not work out for us –not that it is not good, actually it is much cleaner than this solution–. Apache authentication module mod_crowd does not work with SUSE Linux Enterprise Server 11 and it is our infra team’s choice of flavor for production servers 🙂

What I did instead was;

  • I used mod_ldap_auth to do the authentication
  • And made gitolite call a ruby script to retrieve the groups of the user from Crowd.

See the ruby one liner below.

For those who wonder the format of Crowd’s output for the service call, it is as follows.

 

Leave a Reply

Your email address will not be published. Required fields are marked *