Hi,

I'm loading a new GeoTIFF layer using REST by adding a new coveragestore
and coverage (requests below). After that, the layer does not have
information about bands and I have to use the "Reload band definitions"
option in the web GUI to load them manually (because I don't know the
raster metadata and I cannot include it in the request).

Why is the band information not loaded automatically? Is it possible to
load it programmatically without using the web GUI?

I'm using 2.9.1.

$ curl -u admin:geoserver -XPOST
http://localhost:8080/geoserver/rest/workspaces/files/coveragestores.json
-H "Content-Type: application/json" --data '{
  "coverageStore" : {
    "name" : "myraster",
    "type" : "GeoTIFF",
    "enabled" : true,
    "workspace" : {
      "name" : "files"
    },
    "url" : "file:test.tif"
  }
}'

$ curl -u admin:geoserver -XPOST
http://localhost:8080/geoserver/rest/workspaces/files/coveragestores/myraster/coverages.json
-H "Content-Type: application/json" --data '{
  "coverage" : {
    "name" : "myraster",
    "enabled" : true,
    "store" : {
      "name" : "files:myraster"
    }
  }
}'

Best regards.

-- 
Víctor González
http://geomati.co
------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to