Skip to content

Commit

Permalink
Merge branch 'clojure' of github.com:diogok/biodiv-ui into clojure
Browse files Browse the repository at this point in the history
  • Loading branch information
diogok committed Dec 13, 2016
2 parents e0446cf + 759011c commit 98f6508
Show file tree
Hide file tree
Showing 2 changed files with 61 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
FROM diogok/java8:zulu

ENV PORT 80
EXPOSE 80

WORKDIR /opt
CMD ["java","-server","-XX:+UseConcMarkSweepGC","-XX:+UseCompressedOops","-XX:+DoEscapeAnalysis","-DPORT=80","-jar","rrapp-ui.jar"]

ADD target/rrapp-ui-0.0.1-standalone.jar /opt/rrapp-ui.jar

51 changes: 51 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# RRAPP-UI

This is the webinterface for [Rapid Risk Assessment App](https://br.biodiversity.cloud).

It reads and display statistics and visualization from an ElasticSearch with data of [rrapp-idx](https://github.com/biodivdev/rrapp-idx).

## Running

### Manual

First, start your ElasticSearch 5.0.

Then [run the dwc-bot-es](https://github.com/biodivdev/rrapp-idx/) and [run rrapp-idx](https://github.com/biodivdev/rrapp-idx).

This will populate the database.

### Run with Docker

Run the docker container

$ docker run -d -volume /etc/biodiv:/etc/biodiv:ro -p8080:80 diogok/rrapp-ui

### Run the JAR

Download the latest jar from the [ realases page ](https://github.com/biodivdev/rrapp-ui/releases) and run it:

$ java -server -jar rrapp-ui.jar

### Configuration

It will look for a configuration file on /etc/biodiv/config.ini or at the file defined by CONFIG environment variable.

The configuration file looks like the following:

ELASTICSEARCH=http://localhost:9200
INDEX=dwc

ElasticSearch tells to which elasticsearch server to connect. INDEX tells which ElasticSearch index to use.

You can set the configuration override to use with environment variables, such as:

$ CONFIG=/etc/biodiv/dwc.ini ELASTICSEARCH=http://localhost:9200 INDEX=dwc java -jar rrapp-ui.jar

If not running on a system with environment variables you can also set them using java properties, as such:

$ java -jar -DLOOP=true -DCONFIG=/etc/biodiv/config.ini -DELASTICSEARCH=http://localhost:9200 -DINDEX=dwc rrapp-ui.jar

## License

MIT

0 comments on commit 98f6508

Please sign in to comment.