openskope / skope-deployment

Everything needed to deploy SKOPE in a new environment.
0 stars 1 forks source link

GDAL in GeoServer image incompatible with some Docker environments #62

Open tmcphillips opened 6 years ago

tmcphillips commented 6 years ago

When running the SKOPE services on Ubuntu 18.04 in the Windows Subsystem for Linux, the map tiles are not produced correctly by the GeoServer docker image. This appears to be due to failure of the version of the GDAL libraries built into this image to read GeoTIFFs from directories mounted as Docker volumes in this environment:

root@6c71ecb862d8r# ls -l  pmdi_0001-01-01.tif
-rwxrwxrwx 1 root root 32417 Mar 27 16:16 pmdi_0001-01-01.tif

root@6c71ecb862d8# gdalinfo pmdi_0001-01-01.tif
ERROR 1: TIFFOpen:pmdi_0001-01-01.tif: No such file or directory
gdalinfo failed - unable to open 'pmdi_0001-01-01.tif'.

root@6c71ecb862d8# gdalinfo --version
GDAL 1.10.1, released 2013/08/26

Building a more recent version of GDAL (2.1.2, the version used by the timeseries-service image, which can read GeoTIFFs in this setting) in the GeoServer image gives a version that works:

root@6c71ecb862d8# /opt/gdal/gdal-2.1.2/bin/gdalinfo pmdi_0001-01-01.tif | head -2
Driver: GTiff/GeoTIFF
Files: pmdi_0001-01-01.tif

root@6c71ecb862d8# /opt/gdal/gdal-2.1.2/bin/gdalinfo --version
GDAL 2.1.2, released 2016/10/24

We may want to build our own GeoServer Docker images so that we can constrain the version of GDAL it employs to be both up to date and the same as for our other Docker images to minimize surprises of this kind.