-
-
Notifications
You must be signed in to change notification settings - Fork 657
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
make Tabula work under a relative path #586
Conversation
LGTM |
tyvm |
make Tabula work under a relative path
@jeremybmerrill I have been trying to make ROOT_URI, I set an env variable and passed -D ROOT_URI=xx to my docker container but not luck, can you give me a hint do we have modify a file? (I am assuming I don't but I haven't figured it out) |
@jimzucker Can you say more about what goes wrong? |
@jeremybmerrill we are trying to run this container with a different root like /pdf instead of / but we have not found how to set the root in the currently available docker container on docker hub. This is so we can make the container part of a larger website and proxy a route. as we use / for other things we need to add a different root. |
Right, so, what happens when you try? Does Tabula not respond at all under the chosen root? Or does it respond, but not work properly once you're interacting with Tabula? |
FYI, this may've been a typo in your above bug, but the right way to set an env var in Docker is like this |
FYI , I tried with docker run -e ROOT_URI=tabula -p 9292:9292 tabula . It get started on desired url but fails while uploading pdf . jquery.min.js:2 POST http://0.0.0.0:9292/upload.json 404 (Not Found) |
@AbhishekTrivedi2017 yes, I think I fixed that yesterday: 5b9b4b8 try it again? |
@jeremybmerrill Thanks for attention and help ! tried after the last commit . Files are getting uploaded but it redirects at bad url . The redirect URL is again skipping the sub context path . Again we can not remove files from the queue . Thanks |
@AbhishekTrivedi2017 can you try it again? I think I fixed that with 87cbba4, which I pushed just now. |
Thanks . It is working fine as expected @jeremybmerrill ..... |
@AbhishekTrivedi2017 Great, thanks for verifying. |
@jeremybmerrill |
@jazzido and @theta682: Check out this branch and see if it works for you, in the situation you envision for running Tabula under a subpath.
ROOT_URI=tabula bundle exec rackup
should serve a working version of Tabula underlocalhost:9292/tabula/
.I wasn't able to figure out how to set a context path, because my familiarity with Jetty, Tomcat, etc. is basically nothing. So that may not work, but it should be an easy fix at the top of config.ru
will close #110 and #547