Installation for Developers On Windows

Setting Up OpenMRS Developer Environment

(Windows 10)


Dependencies

Before building and compiling OpenMRS you must install the following dependencies:

Java JDK and JRE

                   Check for JDK by going to the command prompt and typing:

                             javac –version

                   The result should be:

                             javac 1.8.0_65

                   or whatever version you currently have

 


Check for JRE by going to the command prompt and typing:

                             java –version

The result should be similar to:

                            java version "1.8.0_65"

                           Java(TM) SE Runtime Environment (build 1.8.0_65-b17)

                          Java HotSpot(TM) 64-Bit Server VM (build 25.65-b01, mixed mode)


 


                            

                OpenMRS requires at least java 1.6

The latest versions of JDK and JRE can be found at the following link:
http://www.oracle.com/technetwork/java/javase/downloads/index.html



          MYSQL

For MySQL you must know MYSQL your root password or have a database ready with username and password

                   http://dev.mysql.com/downloads/mysql/


         








Eclipse IDE for Java EE Developers

                   http://www.eclipse.org/downloads

         

Install Jetty plugin for Eclipse

                   In Eclipse go to Help>Install New Software

 


   

Select Add and enter the following:

                   Name: Jetty

                   Location: http://run-jetty-run.googlecode.com/svn/trunk/updatesite

 



Select Run JettyRun and click Next to install Jetty

 

 

Importing OpenMRS core from Git Hub through Eclipse

          In Eclipse go to File>Import>Git>Projects from Git

 

           

Select Clone URI and enter the following for the URI:

          https://github.com/openmrs/openmrs-core       

 


         

          Select all branches and select a destination for the files.




          After the OpenMRS files have been imported go to File > Import again in Eclipse and 

          select Maven > Existing Maven Projects

 

         

Select Browse and navigate to the openmrs-core folder.

         


Select all projects and click Finish to import openmrs-core into your Eclipse workspace.



 

Compiling OpenMRS

          From the command prompt navigate to the OpenMRS project directory

          Enter the following command:

                   mvn clean install

 

 

Run OpenMRS        

          Download the logic omod and place it in openmrs-core/puppet/modules

                   https://modules.openmrs.org/modules/view.jsp?module=logic

          From command prompt move to openmrs-core/webapp

          Run the following command:

                   mvn jetty:run

          Wait for:

                   [INFO] Started Jetty Server

          Open http://localhost:8080/openmrs