Page 1 of 1 (8 posts)

  • talks about »
  • geo

Tags

Last update:
Wed Oct 1 17:15:07 2014

A Django site.

QGIS Planet

Packaging PostGIS dev releases with Docker

Packaging PostGIS dev releases with Docker

We recently added support for GML curves to PostGIS, which enables TinyOWS to deliver WFS requests with curve geometries. More on this in a later post. This enhancement is in the current PostGIS developement version (SVN master) and not released yet. To enable our customer testing this functionality, we had to build packages for their server environment which is Ubuntu Precise with UbuntuGIS repositories. After working with Linux LXC containers and it's predecessor VServer for years, Docker was a logical choice for a clean reproducible build environment.

Rebuilding a Debian package is usually quite easy:

apt-get build-dep <package>
apt-get source <package>
cd <packagedir>
#Make your changes
dch -i
dpkg-buildpackage

But getting build dependencies for PostGIS currently fails with libssl-dev conflicts, maybe because the dev packages got out of sync after the recent Heartblead updates. So the Dockerfile uses equivs to build a dummy package which satisfies the dependencies.

The command

docker run -v /tmp:/pkg sourcepole/postgis-svn-build-env sh -c 'cp /root/*postgis*.deb /pkg'

loads the Docker image with packages built from the latest SVN version of PostGIS in /root and copies the deb files from the containter into /tmp.

Now we're ready to install these packages on the Ubuntu server:

sudo dpkg -i /tmp/*postgis*.deb

Thats it. Feedback welcome!

@PirminKalberer

P.S.

If you happen to be a developer, then you may prefer running a cutting-edge version of PostGIS in a Docker container instead of building packages. Our colleagues from Oslandia just published how to do this.

„Geo For All“ - neue Technologien für eine Welt im Wandel

GEOSummit 2014, Bern

„Geo for all“ ist nicht nur das Motto der weltumspannenden ICA-OSGeo Lab Initiative zur Förderung der GIS-Ausbildung an Hochschulen, sondern steht allgemein für den immer breiteren Zugang zu professionellen GIS-Werkzeugen. Im Kartenbereich haben Produkte wie TileMill oder D3.js, sowie Dienste wie CartoDB, GeoCommons, usw. den Anwenderkreis weit über das klassische GIS-Fachbebiet hinaus erweitert. Im Vortrag werden einige herausragende Beispiele vorgestellt und deren Relevanz für die Fachwelt erläutert.

@PirminKalberer

Links:

Packaging PostGIS dev releases with Docker

Packaging PostGIS dev releases with Docker

We recently added support for GML curves to PostGIS, which enables TinyOWS to deliver WFS requests with curve geometries. More on this in a later post. This enhancement is in the current PostGIS developement version (SVN master) and not released yet. To enable our customer testing this functionality, we had to build packages for their server environment which is Ubuntu Precise with UbuntuGIS repositories. After working with Linux LXC containers and it's predecessor VServer for years, Docker was a logical choice for a clean reproducible build environment.

Rebuilding a Debian package is usually quite easy:

apt-get build-dep <package>
cd <packagedir>
#Make your changes
dch -i
dpkg-buildpackage

But getting build dependencies for PostGIS currently fails with libssl-dev conflicts, maybe because the dev packages got out of sync after the recent Heartblead updates. So the Dockerfile uses equivs to build a dummy package which satisfies the dependencies.

The command

docker run -v /tmp:/pkg sourcepole/postgis-svn-build-env sh -c 'cp /root/*postgis*.deb /pkg'

loads the Docker image with packages built from the latest SVN version of PostGIS in /root and copies the deb files from the containter into /tmp.

Now we're ready to install these packages on the Ubuntu server:

sudo dpkg -i /tmp/*postgis*.deb

Thats it. Feedback welcome!

@PirminKalberer

P.S.

If you happen to be a developer, then you may prefer running a cutting-edge version of PostGIS in a Docker container instead of building packages. Our colleagues from Oslandia just published how to do this.

PDF reports with embedded maps

Printing is always one of the more difficult parts in a web mapping application. There are solutions like the MapFish Print module or the built-in QGIS WYSIWYG PDF printing. But very often users do not want only a map on their print output, but collected information stored in a database with images, etc. - and a matching map. This is the domain of database reporting tools like JasperReports. They provide desktop tools for designing complex reports with texts, graphics, images, tables, etc. and server software for web applications. But how to include a matching map - a map with application parameters like the bounding box or a list of active layers, etc.?

Sourcepole is releasing the missing link between high-quality map printing and database reports, an extension for JasperReports/iReport. This extension makes it easy to embed maps served with the standardized Web Map Service (WMS) protocol.

With this extension installed as plugin for iReport Designer, you have all the reporting features of JapserReports plus a new toolbox component for embedding maps.

This allows you to create multi-page reports with embedded maps using parameters from your web mapping application and complex Jasper expressions.

Source and documentation of the WMS map extension for Jasper Reports is available on Github and binaries as Github downloads

Many thanks to Mika from Panter for implementing the Java stuff and the Canton of Zurich for sponsoring this useful piece of Open Source software.

@PirminKalberer

PDF reports with embedded maps

Printing is always one of the more difficult parts in a web mapping application. There are solutions like the MapFish Print module or the built-in QGIS WYSIWYG PDF printing. But very often users do not want only a map on their print output, but collected information stored in a database with images, etc. - and a matching map. This is the domain of database reporting tools like JasperReports. They provide desktop tools for designing complex reports with texts, graphics, images, tables, etc. and server software for web applications. But how to include a matching map - a map with application parameters like the bounding box or a list of active layers, etc.?

Sourcepole is releasing the missing link between high-quality map printing and database reports, an extension for JasperReports/iReport. This extension makes it easy to embed maps served with the standardized Web Map Service (WMS) protocol.

With this extension installed as plugin for iReport Designer, you have all the reporting features of JapserReports plus a new toolbox component for embedding maps.

This allows you to create multi-page reports with embedded maps using parameters from your web mapping application and complex Jasper expressions.

Source and documentation of the WMS map extension for Jasper Reports is available on Github and binaries as Github downloads

Many thanks to Mika from Panter for implementing the Java stuff and the Canton of Zurich for sponsoring this useful piece of Open Source software.

@PirminKalberer

Faster maps with progressive WMS

The good old OGC WMS has many advantages compared to tiled maps:

  • Continious zoom levels
  • Support for different projections
  • Combination of multiple layers in one request
  • Higher resolutions for printing
  • Better labelling
  • No maintenance needed when updating data

Well known disadvantages are scalability issues for high-traffic sites and a slower response time for complex maps.

The second point can be significantly improved by using a technique known from the progressive JPEG format. Before loading a map with full resolution, a map image with a lower resolution is requested from the server. This results in a better response time, because rendering and transmitting of the low resolution image is significantly faster. The biggest effect on rendering time is in combination with raster layers, but also for vector layers the improvement can be substantial.

High resolution:

Low resolution:

The technique can be easily applied to any WMS using this basic OpenLayers implementation.

There is much room for improvements. The low resolution layer could be tiled, limited to certain zoom levels or having a larger extend for smoother panning.

QGISCloud has this optimization built into the QGIS Web-Client viewer, which helps collecting experience with a wide range of datasets.

Faster maps with progressive WMS

The good old OGC WMS has many advantages compared to tiled maps:

  • Continious zoom levels
  • Support for different projections
  • Combination of multiple layers in one request
  • Higher resolutions for printing
  • Better labelling
  • No maintenance needed when updating data

Well known disadvantages are scalability issues for high-traffic sites and a slower response time for complex maps.

The second point can be significantly improved by using a technique known from the progressive JPEG format. Before loading a map with full resolution, a map image with a lower resolution is requested from the server. This results in a better response time, because rendering and transmitting of the low resolution image is significantly faster. The biggest effect on rendering time is in combination with raster layers, but also for vector layers the improvement can be substantial.

High resolution:

Low resolution:

The technique can be easily applied to any WMS using this basic OpenLayers implementation.

There is much room for improvements. The low resolution layer could be tiled, limited to certain zoom levels or having a larger extend for smoother panning.

QGISCloud has this optimization built into the QGIS Web-Client viewer, which helps collecting experience with a wide range of datasets.

FOSS4G 2010: SpatiaLite, the Shapefile of the future?

Here are the slides from our presentation at FOSS4G 2010 in Barcelona:

SpatiaLite, the Shapefile of the future?

  • Page 1 of 1 ( 8 posts )
  • geo

Back to Top

Sponsors