Hi.
It’s my first attempt to run my own ORS instance.
I install a brand new docker instance release 9.3.0 and try to run it with default settings.
Unfortunately, it exits quickly at startup with this log
[+] Running 12/12
✔ ors-app Pulled 28.7s
✔ 6e771e15690e Already exists 0.0s
✔ e191a064c87c Pull complete 16.2s
✔ db32b58f5048 Pull complete 17.6s
✔ 4a3cc10f13b6 Pull complete 24.1s
✔ 2b5f600743de Pull complete 24.9s
✔ 3bb282e64e9b Pull complete 25.1s
✔ 2ef345db9beb Pull complete 25.6s
✔ 09ea8ea1b035 Pull complete 25.7s
✔ cb4213c8e236 Pull complete 25.8s
✔ fe41b7fb0084 Pull complete 25.9s
✔ 4f4fb700ef54 Pull complete 26.0s
[+] Running 1/1
✔ Container ors-app Created 3.5s
Attaching to ors-app
ors-app | #################
ors-app | # Container ENV #
ors-app | #################
ors-app | ✓ CONTAINER_LOG_LEVEL: INFO. Set CONTAINER_LOG_LEVEL=DEBUG for more details.
ors-app | ⓘ Any config file settings can be overwritten by environment variables.
ors-app | ⓘ Use 'CONTAINER_LOG_LEVEL=DEBUG' to see the full list of active environment variables for this container.
ors-app | ###########################
ors-app | # Container sanity checks #
ors-app | ###########################
ors-app | ⓘ Running container as user root with id 0 and group 0
ors-app | ✓ ORS_HOME: /home/ors exists and is writable.
ors-app | ✓ Update the file /home/ors/config/example-ors-config.env with /example-ors-config.env
ors-app | ✓ Update the file /home/ors/config/example-ors-config.yml with /example-ors-config.yml
ors-app | ⚠ No config file found. Copying /example-ors-config.yml to /home/ors/config/ors-config.yml
ors-app | ⚠ To adjust your config edit ors-config.yml in your 'config' docker volume or use the environment variable configuration.
ors-app | ✓ Update the file /home/ors/config/ors-config.yml with /example-ors-config.yml
ors-app | ⓘ Default to graphs folder: /home/ors/graphs
ors-app | ⓘ Default to example osm source file: "/home/ors/files/example-heidelberg.test.pbf"
ors-app | ⓘ Any ENV variables will have precedence over configuration variables from config files.
ors-app | ✓ All checks passed. For details set CONTAINER_LOG_LEVEL=DEBUG.
ors-app | #####################################
ors-app | # Container file system preparation #
ors-app | #####################################
ors-app | ✓ Update the file /home/ors/files/example-heidelberg.test.pbf with /heidelberg.test.pbf
ors-app | ✓ Container file system preparation complete. For details set CONTAINER_LOG_LEVEL=DEBUG.
ors-app | #######################################
ors-app | # Prepare CATALINA_OPTS and JAVA_OPTS #
ors-app | #######################################
ors-app | ✓ CATALINA_OPTS and JAVA_OPTS ready. For details set CONTAINER_LOG_LEVEL=DEBUG.
ors-app | #####################
ors-app | # ORS startup phase #
ors-app | #####################
ors-app | ✓ 🙭 Ready to start the ORS application 🙭
ors-app | Exception in thread "main" java.lang.IllegalStateException: No 'Start-Class' manifest entry specified in org.springframework.boot.loader.launch.JarLauncher@6d3af739
ors-app | at org.springframework.boot.loader.launch.ExecutableArchiveLauncher.getMainClass(ExecutableArchiveLauncher.java:70)
ors-app | at org.springframework.boot.loader.launch.Launcher.launch(Launcher.java:63)
ors-app | at org.springframework.boot.loader.launch.JarLauncher.main(JarLauncher.java:40)
ors-app exited with code 1
I found nothing about this java issue here. Can someone help me ?
Hello.
Thank you for your help.
Aside from changing port 8080 to 7080 in the docker-compose.yml file, I do exactly the same.
Are you sure that it’s really started ?
root@Capsule:~/ors93# docker compose up -d
[+] Running 1/1
✔ Container ors-app Started
When I check the log. The ORS app is not started.
root@Capsule:~/ors93# docker logs -f ors-app
#################
# Container ENV #
#################
✓ CONTAINER_LOG_LEVEL: INFO. Set CONTAINER_LOG_LEVEL=DEBUG for more details.
ⓘ Any config file settings can be overwritten by environment variables.
ⓘ Use 'CONTAINER_LOG_LEVEL=DEBUG' to see the full list of active environment variables for this container.
###########################
# Container sanity checks #
###########################
ⓘ Running container as user root with id 0 and group 0
✓ ORS_HOME: /home/ors exists and is writable.
✓ Update the file /home/ors/config/example-ors-config.env with /example-ors-config.env
✓ Update the file /home/ors/config/example-ors-config.yml with /example-ors-config.yml
⚠ No config file found. Copying /example-ors-config.yml to /home/ors/config/ors-config.yml
⚠ To adjust your config edit ors-config.yml in your 'config' docker volume or use the environment variable configuration.
✓ Update the file /home/ors/config/ors-config.yml with /example-ors-config.yml
ⓘ Default to graphs folder: /home/ors/graphs
ⓘ Default to example osm source file: "/home/ors/files/example-heidelberg.test.pbf"
ⓘ Any ENV variables will have precedence over configuration variables from config files.
✓ All checks passed. For details set CONTAINER_LOG_LEVEL=DEBUG.
#####################################
# Container file system preparation #
#####################################
✓ Update the file /home/ors/files/example-heidelberg.test.pbf with /heidelberg.test.pbf
✓ Container file system preparation complete. For details set CONTAINER_LOG_LEVEL=DEBUG.
#######################################
# Prepare CATALINA_OPTS and JAVA_OPTS #
#######################################
✓ CATALINA_OPTS and JAVA_OPTS ready. For details set CONTAINER_LOG_LEVEL=DEBUG.
#####################
# ORS startup phase #
#####################
✓ 🙭 Ready to start the ORS application 🙭
Exception in thread "main" java.lang.IllegalStateException: No 'Start-Class' manifest entry specified in org.springframework.boot.loader.launch.JarLauncher@6d3af739
at org.springframework.boot.loader.launch.ExecutableArchiveLauncher.getMainClass(ExecutableArchiveLauncher.java:70)
at org.springframework.boot.loader.launch.Launcher.launch(Launcher.java:63)
at org.springframework.boot.loader.launch.JarLauncher.main(JarLauncher.java:40)
Sorry, I cannot reproduce the error. For me it’s also working with a different port, e.g. 7080:
services:
# ----------------- ORS application configuration ------------------- #
ors-app:
# Activate the following lines to build the container from the repository
# You have to add --build to the docker compose command to do so
build:
context: ./
container_name: ors-app
ports:
- "7080:8082" # Expose the ORS API on port 8080
- "9001:9001" # Expose additional port for monitoring (optional)
image: openrouteservice/openrouteservice:v9.3.0
...
Maybe you get some hints when setting up debug level, here the snippets of the docker compose file:
-- 8< -- 8< -- 8< -- 8< -- 8< --
environment:
REBUILD_GRAPHS: False # Set to True to rebuild graphs on container start.
CONTAINER_LOG_LEVEL: DEBUG # Log level for the container. Possible values: DEBUG, INFO, WARNING, ERROR, CRITICAL
-- 8< -- 8< -- 8< -- 8< -- 8< --
logging.level.org.heigit: DEBUG
-- 8< -- 8< -- 8< -- 8< -- 8< --
ors-app | #################
ors-app | # Container ENV #
ors-app | #################
ors-app | ✓ CONTAINER_LOG_LEVEL: DEBUG. Set CONTAINER_LOG_LEVEL=DEBUG for more details.
ors-app | ▢ logging.level.org.heigit=DEBUG
ors-app | ▢ XMX=2g
ors-app | ▢ XMS=1g
ors-app | ▢ CONTAINER_LOG_LEVEL=DEBUG
ors-app | ▢ HOSTNAME=86d0b8b17aaf
ors-app | ▢ LANGUAGE=en_US
ors-app | ▢ JAVA_HOME=/usr/lib/jvm/default-jvm
ors-app | ▢ REBUILD_GRAPHS=false
ors-app | ▢ PWD=/home/ors
ors-app | ▢ HOME=/root
ors-app | ▢ LANG=en_US
ors-app | ▢ BUILD_GRAPHS=False
ors-app | ▢ ADDITIONAL_JAVA_OPTS=
ors-app | ▢ SHLVL=1
ors-app | ▢ LC_ALL=en_US
ors-app | ▢ PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/lib/jvm/default-jvm/bin
ors-app | ▢ ORS_HOME=/home/ors
ors-app | ▢ _=/usr/bin/env
ors-app | ⓘ Any config file settings can be overwritten by environment variables.
ors-app | ⓘ Use 'CONTAINER_LOG_LEVEL=DEBUG' to see the full list of active environment variables for this container.
ors-app | ###########################
ors-app | # Container sanity checks #
ors-app | ###########################
ors-app | ⓘ Running container as user root with id 0 and group 0
ors-app | ▢ User and group are set to root with id 0 and group 0.
ors-app | ✓ ORS_HOME: /home/ors exists and is writable.
ors-app | ▢ Populated ORS_HOME=/home/ors with the default folders: files, logs, graphs, elevation_cache, config
ors-app | ▢ ors.engine.profile_default.graph_path= is set and not empty and not set to /
ors-app | ▢ ors.engine.elevation.cache_path= is set and not empty and not set to /
ors-app | ✓ The file /home/ors/config/example-ors-config.env is up to date
ors-app | ✓ The file /home/ors/config/example-ors-config.yml is up to date
ors-app | ✓ Using the existing ors-config.yml from: /home/ors/config/ors-config.yml
ors-app | ⓘ Default to graphs folder: /home/ors/graphs
ors-app | ▢ OSM source file set to /home/ors/files/example-heidelberg.test.pbf
ors-app | ⓘ Default to example osm source file: "/home/ors/files/example-heidelberg.test.pbf"
ors-app | ⓘ Any ENV variables will have precedence over configuration variables from config files.
ors-app | ✓ All checks passed. For details set CONTAINER_LOG_LEVEL=DEBUG.
ors-app | #####################################
ors-app | # Container file system preparation #
ors-app | #####################################
ors-app | ▢ Changed ownership of /home/ors to root
ors-app | ✓ The file /home/ors/files/example-heidelberg.test.pbf is up to date
ors-app | ✓ Container file system preparation complete. For details set CONTAINER_LOG_LEVEL=DEBUG.
ors-app | #######################################
ors-app | # Prepare CATALINA_OPTS and JAVA_OPTS #
ors-app | #######################################
ors-app | ▢ CATALINA_OPTS: -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9001 -Dcom.sun.management.jmxremote.rmi.port=9001 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=localhost
ors-app | ▢ JAVA_OPTS: -Djava.awt.headless=true -server -XX:TargetSurvivorRatio=75 -XX:SurvivorRatio=64 -XX:MaxTenuringThreshold=3 -XX:+UseG1GC -XX:+ScavengeBeforeFullGC -XX:ParallelGCThreads=4 -Xms1g -Xmx2g
ors-app | ✓ CATALINA_OPTS and JAVA_OPTS ready. For details set CONTAINER_LOG_LEVEL=DEBUG.
ors-app | #####################
ors-app | # ORS startup phase #
ors-app | #####################
ors-app | ✓ 🙭 Ready to start the ORS application 🙭
ors-app | ▢ Startup command: java -Djava.awt.headless=true -server -XX:TargetSurvivorRatio=75 -XX:SurvivorRatio=64 -XX:MaxTenuringThreshold=3 -XX:+UseG1GC -XX:+ScavengeBeforeFullGC -XX:ParallelGCThreads=4 -Xms1g -Xmx2g -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9001 -Dcom.sun.management.jmxremote.rmi.port=9001 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=localhost -jar /ors.jar
ors-app | Exception in thread "main" java.lang.IllegalStateException: No 'Start-Class' manifest entry specified in org.springframework.boot.loader.launch.JarLauncher@6d3af739
ors-app | at org.springframework.boot.loader.launch.ExecutableArchiveLauncher.getMainClass(ExecutableArchiveLauncher.java:70)
ors-app | at org.springframework.boot.loader.launch.Launcher.launch(Launcher.java:63)
ors-app | at org.springframework.boot.loader.launch.JarLauncher.main(JarLauncher.java:40)
ors-app exited with code 1
# Docker Compose file for the openrouteservice (ORS) application
# Documentation and examples can be found on https://giscience.github.io/openrouteservice/run-instance/running-with-docker
services:
# ----------------- ORS application configuration ------------------- #
ors-app:
# Activate the following lines to build the container from the repository
# You have to add --build to the docker compose command to do so
build:
context: ./
container_name: ors-app
ports:
- "7080:8082" # Expose the ORS API on port 8080
- "9001:9001" # Expose additional port for monitoring (optional)
image: openrouteservice/openrouteservice:v9.3.0
# Advanced option! If you different ids to 0:0 and 1000:1000, you have to rebuild the container with the build args UID,GID.
# The user command is useful if you want easier bind mount access or better security.
#user: "1000:1000" # Run "mkdir -p ors-docker/config ors-docker/elevation_cache ors-docker/files ors-docker/graphs ors-docker/logs && sudo chown -R 1000:1000 ors" before starting the container!
volumes: # Mount relative directories. ONLY for local container runtime. To switch to docker managed volumes see 'Docker Volumes configuration' section below.
- ./ors-docker:/home/ors # Mount the ORS application directory (for logs, graphs, elevation_cache, etc.) into its own directory
#- ./graphs:/home/ors/graphs # Mount graphs directory individually
#- ./elevation_cache:/home/ors/elevation_cache # Mount elevation cache directory individually
#- ./config:/home/ors/config # Mount configuration directory individually
#- ./logs:/home/ors/logs # Mount logs directory individually
#- ./files:/home/ors/files # Mount files directory individually
environment:
REBUILD_GRAPHS: False # Set to True to rebuild graphs on container start.
CONTAINER_LOG_LEVEL: DEBUG # Log level for the container. Possible values: DEBUG, INFO, WARNING, ERROR, CRITICAL
# If you don't want the default ors-config.yml you can specify a custom file name, that should match the file in
# your 'config' volume mount.
#ORS_CONFIG_LOCATION: /home/ors/config/my-ors-config.yml # Location of your ORS configuration file in the docker container
# ------------------ JAVA OPTS ------------------ #
# Configure the memory settings for JAVA or pass additional opts
# Fore more available ENV properties see Prepare CATALINA_OPTS and JAVA_OPTS
# in https://github.com/GIScience/openrouteservice/blob/main/docker-entrypoint.sh
XMS: 1g # start RAM assigned to java
XMX: 2g # max RAM assigned to java. Rule of Thumb: <PBF-size> * <profiles> * 2
# Example: 1.5 GB pbf size, two profiles (car and foot-walking)
# -> 1.5 * 2 * 2 = 6. Set xmx to be AT LEAST `-Xmx6g`
ADDITIONAL_JAVA_OPTS: "" # further options you want to pass to the java command
# ----------------- Properties configuration ------------------- #
# Configure your whole container with only property ENVs.
# These can be set alternatively or additionally to the yml configuration file.
# Note, that any values set will override the corresponding values from the yml configuration file.
# See the ors-config.env file for more options.
# To have a configuration file-less container, uncomment at least the following properties.
# The values are examples and provide the default configuration.
#ors.engine.profile_default.build.source_file: /home/ors/files/example-heidelberg.test.pbf
#ors.engine.profile_default.graph_path: /home/ors/graphs
#ors.engine.elevation.cache_path: /home/ors/elevation_cache
#ors.engine.profiles.car.enabled: true
logging.level.org.heigit: DEBUG
# ----------------- ENV file configuration ------------------- #
# Too many variables for your 'environment:' section?
# Use an env_file with the ENV properties instead and define everything in there:
# Values will be overwritten if set in the 'environment' section.
#env_file: ors-config.env
# ----------------- Healthcheck configuration ------------------- #
# The healthcheck is disabled by default. Uncomment the following lines to enable it.
# The healthcheck allows you to monitor the status of the ORS application.
# Be careful with long graph builds, as the healthcheck will fail and show 'unhealthy' during this time.
# This is especially useful if you run your ORS container in a production environment.
#healthcheck:
# test: wget --no-verbose --tries=1 --spider http://localhost:8082/ors/v2/health || exit 1
# start_period: 1m
# interval: 10s
# timeout: 2s
# retries: 3
# disable: false
# ----------------- Docker Volumes configuration ------------------- #
# Define the Docker managed volumes for the ORS application. For more info on Docker Volumes see https://docs.docker.com/compose/compose-file/07-volumes/
# Volumes are used to persist the data and configuration of the ORS application.
# If you want to use volumes, uncomment the following lines and remove the ./ prefix from the volume paths in 'services.ors-app.volumes'.
#volumes:
# graphs:
# elevation_cache:
# config:
# logs:
# files:
I have tested each release on github.
They all works until 9.2.0 which exit as the 9.3.1 release but for another reason.
ors-app920 | #################
ors-app920 | # Container ENV #
ors-app920 | #################
ors-app920 | ✓ CONTAINER_LOG_LEVEL: DEBUG. Set CONTAINER_LOG_LEVEL=DEBUG for more details.
ors-app920 | ▢ XMX=2g
ors-app920 | ▢ XMS=1g
ors-app920 | ▢ CONTAINER_LOG_LEVEL=DEBUG
ors-app920 | ▢ HOSTNAME=4dfb678f0526
ors-app920 | ▢ LANGUAGE=en_US
ors-app920 | ▢ JAVA_HOME=/usr/lib/jvm/default-jvm
ors-app920 | ▢ REBUILD_GRAPHS=false
ors-app920 | ▢ PWD=/home/ors
ors-app920 | ▢ HOME=/root
ors-app920 | ▢ LANG=en_US
ors-app920 | ▢ BUILD_GRAPHS=False
ors-app920 | ▢ ADDITIONAL_JAVA_OPTS=
ors-app920 | ▢ SHLVL=1
ors-app920 | ▢ LC_ALL=en_US
ors-app920 | ▢ PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/lib/jvm/default-jvm/bin
ors-app920 | ▢ ORS_HOME=/home/ors
ors-app920 | ▢ _=/usr/bin/env
ors-app920 | ⓘ Any config file settings can be overwritten by environment variables.
ors-app920 | ⓘ Use 'CONTAINER_LOG_LEVEL=DEBUG' to see the full list of active environment variables for this container.
ors-app920 | ###########################
ors-app920 | # Container sanity checks #
ors-app920 | ###########################
ors-app920 | ⓘ Running container as user root with id 0 and group 0
ors-app920 | ▢ User and group are set to root with id 0 and group 0.
ors-app920 | ✓ ORS_HOME: /home/ors exists and is writable.
ors-app920 | ▢ Populated ORS_HOME=/home/ors with the default folders: files, logs, graphs, elevation_cache, config
ors-app920 | ▢ ors.engine.profile_default.graph_path= is set and not empty and not set to /
ors-app920 | ▢ ors.engine.elevation.cache_path= is set and not empty and not set to /
ors-app920 | ✓ The file /home/ors/config/example-ors-config.env is up to date
ors-app920 | ✓ The file /home/ors/config/example-ors-config.yml is up to date
ors-app920 | ✓ Using the existing ors-config.yml from: /home/ors/config/ors-config.yml
ors-app920 | ⓘ Default to graphs folder: /home/ors/graphs
ors-app920 | ▢ OSM source file set to /home/ors/files/example-heidelberg.test.pbf
ors-app920 | ⓘ Default to example osm source file: "/home/ors/files/example-heidelberg.test.pbf"
ors-app920 | ⓘ Any ENV variables will have precedence over configuration variables from config files.
ors-app920 | ✓ All checks passed. For details set CONTAINER_LOG_LEVEL=DEBUG.
ors-app920 | #####################################
ors-app920 | # Container file system preparation #
ors-app920 | #####################################
ors-app920 | ▢ Changed ownership of /home/ors to root
ors-app920 | ✓ The file /home/ors/files/example-heidelberg.test.pbf is up to date
ors-app920 | ✓ Container file system preparation complete. For details set CONTAINER_LOG_LEVEL=DEBUG.
ors-app920 | #######################################
ors-app920 | # Prepare CATALINA_OPTS and JAVA_OPTS #
ors-app920 | #######################################
ors-app920 | ▢ CATALINA_OPTS: -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9001 -Dcom.sun.management.jmxremote.rmi.port=9001 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=localhost
ors-app920 | ▢ JAVA_OPTS: -Djava.awt.headless=true -server -XX:TargetSurvivorRatio=75 -XX:SurvivorRatio=64 -XX:MaxTenuringThreshold=3 -XX:+UseG1GC -XX:+ScavengeBeforeFullGC -XX:ParallelGCThreads=4 -Xms1g -Xmx2g
ors-app920 | ✓ CATALINA_OPTS and JAVA_OPTS ready. For details set CONTAINER_LOG_LEVEL=DEBUG.
ors-app920 | #####################
ors-app920 | # ORS startup phase #
ors-app920 | #####################
ors-app920 | ✓ 🙭 Ready to start the ORS application 🙭
ors-app920 | ▢ Startup command: java -Djava.awt.headless=true -server -XX:TargetSurvivorRatio=75 -XX:SurvivorRatio=64 -XX:MaxTenuringThreshold=3 -XX:+UseG1GC -XX:+ScavengeBeforeFullGC -XX:ParallelGCThreads=4 -Xms1g -Xmx2g -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9001 -Dcom.sun.management.jmxremote.rmi.port=9001 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=localhost -jar /ors.jar
ors-app920 exited with code 1
I cannot find any issue with the provided docker compose file, and for me, everything works fine as well.
I’d suggest starting over from scratch, i.e. deleting all docker images, related files and the like.
Then, just wget the docker-compose.yml and do a docker compose up -d to see what happens