Coder Social home page Coder Social logo

marcoteixeira1977 / docker-qgis-server Goto Github PK

View Code? Open in Web Editor NEW

This project forked from camptocamp/docker-qgis-server

0.0 0.0 0.0 815 KB

All that is needed to generate a proper QGIS server image

Shell 13.07% Python 16.72% Makefile 10.52% Dockerfile 59.69%

docker-qgis-server's Introduction

Docker image for QGIS server

Usage

Expects a project.qgs project file and all the files it depends on in the /etc/qgisserver/ directory. Either you create another image to add those files or you inject them using a volume. For example:

docker run --detach --publish=8380:80 --volume=$PWD/etc/qgisserver:/etc/qgisserver camptocamp/qgis-server

With the previous command, you'll get to your server with this URL: http://localhost:8380/?SERVICE=WMS&REQUEST=GetCapabilities

Tuning

You can use the following variables (-e option in docker run):

  • QGIS_CATCH_SEGV: Set to 1 if you want stacktraces in the logs in case of segmentation faults.
  • FCGID_MAX_REQUESTS_PER_PROCESS: The number of requests a QGIS server will serve before being restarted by apache
  • FCGID_MIN_PROCESSES: The minimum number of fcgi processes to keep (defaults to 1)
  • FCGID_MAX_PROCESSES: The maximum number of fcgi processes to keep (defaults to 5)
  • FCGID_IO_TIMEOUT: This is the maximum period of time the module will wait while trying to read from or write to a FastCGI application (default is 40)
  • FCGID_BUSY_TIMEOUT: The maximum time limit for request handling (defaults to 300)
  • FCGID_IDLE_TIMEOUT: Application processes which have not handled a request for this period of time will be terminated (defaults to 300)
  • FILTER_ENV: Filter the environment variables with e.g.: | grep -vi _SERVICE_ | grep -vi _TCP | grep -vi _UDP | grep -vi _PORT to remove the default Kubernetes environment variables (default in an empty string)
  • GET_ENV: alternative to FILTER_ENV, a command that return the environment variables (defaults to env)

See also QGIS server documentation

Fonts present in the /etc/qgisserver/fonts directory will be installed and thus usable by QGIS.

Running the client

If you want to edit a project file, you can run the client from a Linux machine with the following command:

docker run --rm -ti --env=DISPLAY=unix${DISPLAY} --volume=/tmp/.X11-unix:/tmp/.X11-unix --volume=${HOME}:${HOME} camptocamp/qgis-server:master-desktop

Changelog

QGIS 3.22

We removed the default values for the following environment variables to better fit with the QGIS documentation:

  • QGIS_SERVER_LOG_LEVEL, was 0
  • QGIS_PROJECT_FILE, was /etc/qgisserver/project.qgs
  • MAX_CACHE_LAYERS, was ""
  • QGIS_AUTH_DB_DIR_PATH, was /etc/qgisserver/
  • PGSERVICEFILE, was /etc/qgisserver/pg_service.conf

docker-qgis-server's People

Contributors

sbrunner avatar dependabot[bot] avatar renovate[bot] avatar yjacolin avatar pvalsecc avatar ismailsunni avatar renovate-bot avatar ochriste avatar danduk82 avatar fredj avatar gberaudo avatar snyk-bot avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.