Skip to content
Permalink
Browse files

Add basic scripts to build and run QGIS Server

  • Loading branch information
pblottiere authored and nyalldawson committed Sep 10, 2020
1 parent 71dcf98 commit e5989c1387045d8a2e5ff2e8641c3a127a4b8336
Showing with 85 additions and 0 deletions.
  1. +42 −0 .ci/ogc/Dockerfile
  2. +36 −0 .ci/ogc/build.sh
  3. +7 −0 .ci/ogc/qgis_mapserv.sh
@@ -0,0 +1,42 @@
FROM ubuntu:latest
MAINTAINER Paul Blottiere <blottiere.paul@gmail.com>
RUN export DEBIAN_FRONTEND=noninteractive
ENV DEBIAN_FRONTEND noninteractive

RUN apt-get update \
&& apt-get upgrade -y \
&& apt-get install -y \
cmake \
ninja-build \
ccache \
clang \
flex \
bison \
libgeos-dev \
libgdal-dev \
libzip-dev \
libprotobuf-dev \
qtbase5-dev \
libqt5svg5-dev \
libqt5serialport5-dev \
qttools5-dev \
protobuf-compiler \
qt5-default \
qtpositioning5-dev \
libqt5webkit5-dev \
libqca-qt5-2-dev \
libgsl-dev \
libspatialindex-dev \
qt5keychain-dev \
libexiv2-dev \
libfcgi-dev \
libqt5scintilla2-dev \
libqwt-qt5-dev \
pyqt5-dev \
python3-pyqt5 \
python3-pyqt5.qsci \
pyqt5-dev-tools \
spawn-fcgi

ADD qgis_mapserv.sh /root/qgis_mapserv.sh
CMD ["sh", "/root/qgis_mapserv.sh"]
@@ -0,0 +1,36 @@
#!/bin/bash

mkdir /usr/src/qgis/build
cd /usr/src/qgis/build || exit -1

ccache -s

cmake -GNinja \
-DWITH_QUICK=OFF \
-DWITH_3D=OFF \
-DWITH_STAGED_PLUGINS=OFF \
-DWITH_GRASS=OFF \
-DSUPPRESS_QT_WARNINGS=ON \
-DENABLE_MODELTEST=OFF \
-DENABLE_PGTEST=OFF \
-DENABLE_SAGA_TESTS=OFF \
-DENABLE_MSSQLTEST=OFF \
-DWITH_QSPATIALITE=OFF \
-DWITH_QWTPOLAR=OFF \
-DWITH_APIDOC=OFF \
-DWITH_ASTYLE=OFF \
-DWITH_DESKTOP=OFF \
-DWITH_BINDINGS=ON \
-DWITH_SERVER=ON \
-DWITH_SERVER_PLUGINS=ON \
-DWITH_ORACLE=OFF \
-DDISABLE_DEPRECATED=ON \
-DCXX_EXTRA_FLAGS="${CLANG_WARNINGS}" \
-DCMAKE_C_COMPILER=/usr/lib/ccache/clang \
-DCMAKE_CXX_COMPILER=/usr/lib/ccache/clang++ \
-DADD_CLAZY_CHECKS=OFF \
..

ninja

ccache -s
@@ -0,0 +1,7 @@
#!/bin/bash

export QGIS_SERVER_LOG_FILE=/var/log/qgisserver.log
export QGIS_SERVER_LOG_LEVEL=0
export QGIS_PREFIX_PATH=/usr/local/

exec /usr/bin/spawn-fcgi -n -p 5555 /usr/local/bin/qgis_mapserv.fcgi

0 comments on commit e5989c1

Please sign in to comment.
You can’t perform that action at this time.