metno / metsis-drupal

contains METNO METSIS software
GNU General Public License v3.0
0 stars 0 forks source link

metsis_ts_bokeh - Access API running a Docker services #2

Closed epifanio closed 4 years ago

epifanio commented 4 years ago

in the metsis_ts_bokeh module, when the Plotting routing is called via its IP (e.g.: http://0.0.0.0/basket/tsplot?get=param&resource_url=http://hyrax:8080/opendap/SN99938.nc ) -- the plot is rendered correctly -- But when the URL supplied to the system, is using the "service-name" used in the Docker-compose environment (e.g.: http://fastapi/basket/tsplot?get=param&resource_url=http://hyrax:8080/opendap/SN99938.nc ) The module is able to fetch the list of plotting variables but then fails to retrieve the json data needed to render the plot.

The log in the browser console shos:

Failed to load resource: net::ERR_NAME_RESOLUTION_FAILED
3:36
Uncaught (in promise) TypeError: Failed to fetch
epifanio commented 4 years ago

I also tried to expose the service in docker on the "outside" so that is is available at:

http://localhost:7000/basket/tsplot?get=param&resource_url=http://hyrax:8080/opendap/SN99938.nc

But then drupal doesn't execute neither the get parameter request and returns the following log:

Service call did not succeed. Ensure that the following URL is correct.

http://localhost:7000/basket/tsplot?get=param&resource_url=http://hyrax:8080/opendap/SN99938.nc
flekksteinbit commented 4 years ago

Not an issue on live system.