OpenElis installation on local windows machine

I was trying to install OpenElis on my local machine (Windows). I am using IntelliJ and installed all the requirements given in the readme like Java 1.7, ant version 1.9.1, ruby 2.2.1, and compass 0.12.7. After I tried to build it using the command: ant dist

I am getting this:

compass.compile:

BUILD FAILED C:\Users\Amaresh.C\Desktop\OpenElis-master\OpenElis-master\build.xml:44: Execute failed: java.io.IOException: Cannot run program “compass” (in directory “C:\Users\Amaresh.C\Desktop\OpenElis-master\OpenElis-master\openelis\WebContent”): CreateProcess error=2, The system cannot find the file specified at java.lang.ProcessBuilder.start(ProcessBuilder.java:1047) at java.lang.Runtime.exec(Runtime.java:617) at org.apache.tools.ant.taskdefs.launcher.Java13CommandLauncher.exec(Java13CommandLauncher.java:41) at org.apache.tools.ant.taskdefs.Execute.launch(Execute.java:428) at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:442) at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java:628) at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:669) at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:495) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292) at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:435) at org.apache.tools.ant.Target.performTasks(Target.java:456) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393) at java.lang.ProcessImpl.(ProcessImpl.java:385) at java.lang.ProcessImpl.start(ProcessImpl.java:136) at java.lang.ProcessBuilder.start(ProcessBuilder.java:1028) … 23 more

I don’t understand why I am getting this eventhough I installed compass.

Also when I run the command: ant setupDB test test-only dist It is giving:

Buildfile: C:\Users\Amaresh.C\Desktop\OpenElis-master\OpenElis-master\build.xml Trying to override old definition of task javac

initDB:

BUILD FAILED C:\Users\Amaresh.C\Desktop\OpenElis-master\OpenElis-master\build.xml:150: Execute failed: java.io.IOException: Cannot run program “scripts\initDB.sh”: CreateProcess error=193, %1 is not a valid Win32 application at java.lang.ProcessBuilder.start(ProcessBuilder.java:1047) at java.lang.Runtime.exec(Runtime.java:617) at org.apache.tools.ant.taskdefs.launcher.Java13CommandLauncher.exec(Java13CommandLauncher.java:41) at org.apache.tools.ant.taskdefs.Execute.launch(Execute.java:428) at org.apache.tools.ant.taskdefs.Execute.execute(Execute.java:442) at org.apache.tools.ant.taskdefs.ExecTask.runExecute(ExecTask.java:628) at org.apache.tools.ant.taskdefs.ExecTask.runExec(ExecTask.java:669) at org.apache.tools.ant.taskdefs.ExecTask.execute(ExecTask.java:495) at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106) at org.apache.tools.ant.Task.perform(Task.java:348) at org.apache.tools.ant.Target.execute(Target.java:435) at org.apache.tools.ant.Target.performTasks(Target.java:456) at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393) at org.apache.tools.ant.Project.executeTarget(Project.java:1364) at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41) at org.apache.tools.ant.Project.executeTargets(Project.java:1248) at org.apache.tools.ant.Main.runBuild(Main.java:851) at org.apache.tools.ant.Main.startAnt(Main.java:235) at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280) at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109) Caused by: java.io.IOException: CreateProcess error=193, %1 is not a valid Win32 application at java.lang.ProcessImpl.create(Native Method) at java.lang.ProcessImpl.(ProcessImpl.java:385) at java.lang.ProcessImpl.start(ProcessImpl.java:136) at java.lang.ProcessBuilder.start(ProcessBuilder.java:1028) … 24 more

Why is this happening? Are there some changes required to run the script or is there some way?

Please can someone help me.? Thanks in advance :slight_smile:

Which version are you trying to install ??
and which instructions are you trying to follow ??

you could to try out the latest version in docker-compose

I am trying to build and run OpenElis from the source code from its official repo: GitHub - Bahmni/OpenElis: Fork of OpenELIS for managing Lab workflows (Tests, Results, Samples, etc).

I am trying to follow the requirements and instructions given in that repo.
I want to run it from my local machine using source code and not use docker or docker image.

Alright . Thats a different fork .
We officially maintain the latest version of OpenELIS

So you recommend me to follow this repo: GitHub - I-TECH-UW/OpenELIS-Global-2: OpenELIS 2.X is a rewrite of the original OpenELIS global with updated components and technology
to build and run openelis in my local without docker?

What changes do I need to make to the application code to make it run in my Apache Tomcat and connect it with a PostgreSQL database?

We have docker setup preconfigured to run out of the box.

To run with Tomcat and Postgre on your local machine , see the dev setup

I’ve created the docker-compose.yml file in the top-level directory of my OpenELIS codebase. What should be my next steps to install the OpenELIS setup and continue with my contributions

@Shad_Ali Can you point me to the Actual CodeBase you cloned ??

Our CodeBase already includes a docker-compose.yml file at the root

.Can you simply follow the instructions here

Sure, on my end, I’ll follow the instructions provided. Thanks!

Can give in details all the steps you’ve taken so far , starting from what codebase you cloned ??

Hey Ali, how did you get on? I also want to run the source code locally on a windows desktop. I’m from a Microsoft .NET background, with no experience of either linux or the java stack and so I’m expecting this process to be painful. I’ve installed eclipse and ideally would like to be able to debug the source in the ide rather than run it in a container. But I guess I should take it one step at a time and do a local installation, running in docker.
Thanks

We have a native way to run OpenELIS from source code , directly from the IDE with Tomat and Postgre DB . see instructions

Thanks, Moses, will give that a try on Windows desktop.