OpenMRS Atlas GSoC 2019 - Community Bonding Period

Thanks to the mentors of the project, and the community for selecting me for this project, and helping me along the way. I am really thrilled to be working on this project, and can’t wait to get stuff going!

Image for post
Image for post

Project Details

OpenMRS Atlas is this really neat web application that allows one to view OpenMRS implementations around the world. Users can add markers that are now viewable on Atlas. Unfortunately, when OpenMRS switched to using LDAP, Atlas started to break, and markers could no longer be created/updated. Older markers started to fade. A Node.js implementation of Atlas to fix this was worked on, in a previous year, but the application could never fully be deployed, due to missing authentication functionality. So the task at hand is to fully deploy Atlas, by adding functioning authentication routes, and additional functionality like admin privileges, downloading images, etc.

OpenMRS Atlas

Work so far

I was pretty busy with my exams until 20th May, so I could scrape little time in between. However, I managed to get an LDAP server running locally, and implemented a login page, with Cintia’s help. The changes can be found here: https://github.com/HelioStrike/openmrs-contrib-atlas/tree/3.x-auth

Short video of what I’ve done: https://www.youtube.com/watch?v=HakW9GrcNbw

Getting LDAP running locally

  • Clone the repository openmrs-contrib-ansible-docker-compose
  • Navigate to files/ldap-stg
  • After making sure that your default docker-machine is running, type in the following command to create a server with a bunch of test users.
docker-compose up -d
  • The users’ description can be found in the files present in the bootstrap folder.

Implementing Login

Cintia pointed out that the openmrs-contrib-id repo’s implementation of authentication is pretty similar to what we’d like Atlas to have. I had to create a simple login page but copying most of the LDAP code from id’s repo, and calling the authenticate function from the login route did the trick.

Next Steps

  • As I borrowed code from elsewhere, I will have to clean it up and organize the borrowed file properly.
  • Implement sessions to hold the authenticated user’s data.
  • Add some CSS to the login page... I think that can wait.

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch

Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore

Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store