isamplesorg / export_client

Client for the iSamples export service
Apache License 2.0
1 stars 1 forks source link

Add a local http server to the export client to facilitate local viewing of the exported data #11

Open datadavev opened 3 months ago

datadavev commented 3 months ago

Adding a local http server for the exported content means we can use some off the shelf tools for viewing the content (e.g. stac-browser)and also extend something like observable framework for more detailed viewing.

The http server should:

Some options include aiohttp (which can run as a standalone server) and fastapi (which requires something like uvicorn). Both support the requirements except for byte range requests which seem to require some extension. Preference is towards fastapi since that is used in iSB and there may be some future where a local collection might be exposed as a "iSB light", perhaps.

For testing purposes I've been using the node http-server with the options:

http-server --cors -p 8080 -a 127.0.0.1  -c5

Which serves up current folder to localhost port 8080 with 5 second cache timeout.

Task here is to see if we can add in a python web server as part of the export client to provide a browser based viewer for the exported content.

dannymandel commented 3 months ago

https://github.com/isamplesorg/export_client/commit/b2d70f8fe12fbf59f306a198e2a71d271fc97568