base_url doesn't seem to work when adding criteria and clicking "apply"
See original GitHub issueOver on Apache Tika, we’re using datasette to allow users to make sense of the metadata for our file regression testing corpus.
This could be user error in how I’ve set up the reverse proxy!
I started datasette like so:
docker run -d -p 8001:8001 -v
pwd:/mnt datasetteproject/datasette datasette -p 8001 -h 0.0.0.0 /mnt/corpora-metadata.db --config sql_time_limit_ms:60000 --config base_url:/datasette/
I then reverse proxied like so:
ProxyPreserveHost On ProxyPass /datasette http://x.y.z.q:xxxx ProxyPassReverse /datasette http://x.y.z.q:xxx
Regular sql works perfectly: https://corpora.tika.apache.org/datasette/corpora-metadata?sql=select+mime_string%2C+count(1)+as+cnt from+profiles+p join+mimes+m+on+p.mime_id%3Dm.mime_id group+by+mime_string order+by+cnt+desc
However, adding criteria and clicking ‘Apply’ https://corpora.tika.apache.org/datasette/corpora-metadata/tika_1_24_1_mimes?_sort=file&mime__exact=text%2Fplain
bounces back to: https://corpora.tika.apache.org/corpora-metadata/tika_1_24_1_mimes?_sort=file&file__contains=bug&mime__exact=text%2Fplain
Issue Analytics
- State:
- Created 3 years ago
- Comments:11 (8 by maintainers)
Top GitHub Comments
@tballison thanks, I’ve split that out into a new issue #1091
It looks like there are places where Datasette might return a redirect that doesn’t take
base_url
into account - I’m planning on fixing those here, after which I thinkProxyPassReverse
should no longer be necessary. https://github.com/simonw/datasette/issues/1025#issuecomment-709632136