Geonovum / ogc-api-testbed

OGC API Testbed Template - Stable
https://apitestbed.geonovum.nl
GNU General Public License v3.0
4 stars 4 forks source link

add a service based on ldproxy #7

Closed pvgenuchten closed 3 years ago

pvgenuchten commented 3 years ago

@justb4 can you verify on this PR if it is a valid approach to add an additional service, i have not been able to test locally (expect for the docker-compose itself). Let me know your thoughts. Thanx

pvgenuchten commented 3 years ago

think the ldproxy data/config dir is missing as it is referred in docker-compose.yml

For now i have no data yet, so the data dir is created but empty (i used manual configuration to set up a wfs backend)

if there is a lot of data, not fit for GitHub we need other data strategy

What do you think about these options:

portmapping: all requests go through Traefik, think only 7080 needs exposure

ok

the service needs to be added to services/start.sh/stop.sh

Sure? I noticed:

SERVICES="$(find ${SCRIPT_DIR} -maxdepth 1 -mindepth 1)"
for SERVICE in ${SERVICES} do   
pushd ${SERVICE}        
./start.sh

need to update the deploy.yml (need to add fine-grained deploy later)

ok

don't know if ldproxy can work on a subpath automatically (for pygeoapi we needed to add SCRIPT_PATH).

Me neither, i can ask or we can find out

justb4 commented 3 years ago

think the ldproxy data/config dir is missing as it is referred in docker-compose.yml

For now i have no data yet, so the data dir is created but empty (i used manual configuration to set up a wfs backend) ok let's start with WFS-only

if there is a lot of data, not fit for GitHub we need other data strategy

What do you think about these options:

  • download it from its original location (once at volume creation)
  • reference a remote postgres database See issue #10

portmapping: all requests go through Traefik, think only 7080 needs exposure

ok

the service needs to be added to services/start.sh/stop.sh

Sure? I noticed:

SERVICES="$(find ${SCRIPT_DIR} -maxdepth 1 -mindepth 1)"
for SERVICE in ${SERVICES} do 
pushd ${SERVICE}      
./start.sh

Yes, I just added that, so this does not apply anymore!

need to update the deploy.yml (need to add fine-grained deploy later)

ok See issue #9

don't know if ldproxy can work on a subpath automatically (for pygeoapi we needed to add SCRIPT_PATH).

Me neither, i can ask or we can find out Yes this is always an issue, possibly on their Gitter or maybe that is in documentation.

If I fixed the Traefik config correctly you can now also run the stack locally, e.g. on MacOSX Docker Desktop.

justb4 commented 3 years ago

Running ldproxy on URL with Subpath: https://github.com/interactive-instruments/ldproxy/blob/master/docs/de/configuration/global-configuration.md#external-url Though this does not work locally.

pvgenuchten commented 3 years ago

do you get an error from ldproxy? i will try to run locally

justb4 commented 3 years ago

@pvgenuchten

    ports:
      - 7180:7080
    expose:
      - 7080

and try http://localhost:7180/rest/services ?