-
Notifications
You must be signed in to change notification settings - Fork 412
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #22 from GIScience/development
Instructions for installation
- Loading branch information
Showing
13 changed files
with
110 additions
and
188 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
# Install and Run OpenRouteService Backend via Docker | ||
|
||
It's possible and easy to install and launch the OpenRouteService backend service with Docker. Please note that the [Dockerfile](../Dockerfile) under the repository root directory is only for building the [WAR file](https://www.wikiwand.com/en/WAR_(file_format)). | ||
|
||
## Short version | ||
|
||
run the following command within this `docker/` directory: | ||
|
||
```bash | ||
docker-compose up | ||
``` | ||
|
||
It will: | ||
|
||
1. build and test the OpenRouteService core from the local codebase with the `docker/conf/app.config.sample` as the config and the dataset for Heidelberg under `docker/data/` as sample data; | ||
2. generate the built `ors.war` file and expose it to `docker/build/` directory; | ||
3. launch the OpenRouteService backend service on port `8080`. | ||
|
||
The service status is queryable via `http://localhost:8080/ors/health` endpoint. When the service is ready, go to `http://localhost:8080/ors/status` and it will show more detailed information. A URL for test can be `http://localhost:8080/ors/routes?profile=foot-walking&coordinates=8.676581,49.418204|8.692803,49.409465`. It should be able to provide the recommanded walking path in JSON format. | ||
|
||
## Long version | ||
|
||
### WAR file building | ||
|
||
For building the WAR file only, either run | ||
|
||
```bash | ||
docker run -v /Users/user/build:/ors-core/build giscience/openrouteservice | ||
``` | ||
|
||
or | ||
|
||
```bash | ||
docker-compose up ors-build | ||
``` | ||
|
||
If everything goes fine, the built `ors.war` file can be found under the host directory, e.g. `/Users/user/build` in the above `docker run` command or `./build/` in the `docker-compose` command. | ||
|
||
### Run OpenRouteService | ||
|
||
No matter whether the WAR file has been built or not, run | ||
|
||
```bash | ||
docker-compose up | ||
``` | ||
|
||
will get everything done with the sample Heidelberg dataset. | ||
|
||
### Run with your own OSM dataset | ||
|
||
Prepare the OSM dataset (formats support `.osm`, `.osm.gz`, `.osm.zip`, `.pbf`) in the `docker/data/` directory. Make your own `app.config` (check the sample with detailed comments [here](../openrouteservice/WebContent/WEB-INF/app.config.sample) for reference) and change the `APP_CONFIG` variable in `docker-compose.yml` to let it point to your customized `app.config`. Then, run `docker-compose up`. | ||
|
||
It should be noticed that if your dataset is very big, please adjust the `-Xmx` parameter of `JAVA_OPTS` in `docker-compose.yml`. According to our experiences, it should be at least `180g` for the whole globe. |
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
openrouteservice-api-tests/.settings/org.eclipse.core.resources.prefs
This file was deleted.
Oops, something went wrong.
13 changes: 0 additions & 13 deletions
13
openrouteservice-api-tests/.settings/org.eclipse.jdt.core.prefs
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
openrouteservice-api-tests/.settings/org.eclipse.m2e.core.prefs
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.