openrouteservice
openrouteservice copied to clipboard
Swagger-UI missing on Docker
Here's what I did
I cloned the latest repo, with the intent of starting up an instance with docker. I'm running the north-america map on 16 cores, 128gb ram. Upon starting up the container and letting it complete the setup, I am unable to get the swagger page to load and/or find it.
Here's what I got
http://172.16.242.230:8080/ors/swagger-resources
[
{
name: "default",
url: "/v2/api-docs",
swaggerVersion: "2.0",
location: "/v2/api-docs"
}
]
http://172.16.242.230:8080/ors/v2/api-docs
Contains the raw api data
I have tried every endpoint I can think of, based on swagger/springfox docs. http://172.16.242.230:8080/ors/v2/swagger-ui http://172.16.242.230:8080/ors/v2/swagger-ui/ http://172.16.242.230:8080/ors/v2/swagger-ui.html http://172.16.242.230:8080/ors/swagger-ui http://172.16.242.230:8080/ors/swagger-ui/ http://172.16.242.230:8080/ors/swagger-ui.html http://172.16.242.230:8080/swagger-ui/ http://172.16.242.230:8080/swagger-ui/ http://172.16.242.230:8080/swagger-ui.html
I jumped on the docker container and searched the various resources/META-INF/Web folders and could not find a swagger jar
Here's what I was expecting
I was expecting that with swagger integrated, I would be able to find a swagger-ui on my docker local setup.
Here's what I think could be improved
I'd love to be able to view/use the swagger-ui in the docker deployment. If it does exist, I'd love to see it somewhere in the docs, as I searched those too.
Hi @TheDropZone,
we currently don't provide the swagger UI in our repository. As we host several different services next to the openrouteservice backend via our API, we are using our custom Documentation which also hides some technical endpoints that are not accessible by users. (see https://openrouteservice.org/dev/#/api-docs)
If you want to use the normal swagger UI you could also just copy the output of
http://172.16.242.230:8080/ors/v2/api-docs
to https://editor.swagger.io/.
Also please take note of https://github.com/GIScience/openrouteservice/issues/1025
Of course we can still discuss having the UI directly in the repo.
Best regards
@TheDropZone,
so for now we decided to not include this. Feel free to create a PR for this though.
@TheGreatRefrigerator Thanks so much for the clarification! I had been poking around in the source and noticed the reference to "swagger-ui.html" and figured I was just not looking in the right place for it. Also, I like the ideas in #1025. Sounds like some great stuff