Demonstation of qgis (https://www.qgis.org) on ppc64le. Here, we have supplied a Dockerfile to build container image that runs QGIS Server on ppc64le
Attribution: This is just demonstation of how one can use QGIS inside docker container for an architecture like ppc64le, and not original work. Please refer to https://www.qgis.org ,for complete introduction and details about the free opensource professional and powerful desktop GIS.
QGIS documentation: https://www.qgis.org/en/docs/index.html
Step 1: Clone the repositoy, Navigate to ppc64le-qgis
$ git clone https://github.com/mithunhr87/ppc64le-qgis.git
$ cd ppc64le-qgis
Step 2: Build the docker image , Please substitute the image name and version you prefer in below command
$ export IMAGE=ppc64le
$ export TAG=qgis
$ docker build -t $IMAGE:$TAG .
Step 3: Run the docker image with port mapping , first entry will be hostport, second port entry is container port, Here we have used 6080 at both the places The docker image uses noVNC - https://github.com/novnc/noVNC to provision VNC to browser
$ docker run -it -p 6080:6080 $IMAGE:$TAG
Step4: once the container is running, Navigate to http://<hostname>:6080/vnc.html
, TestVNC is the password, can be changed in entrypoint.sh script as needed. qgis running inside a container will appear on successfull connection to vnc
A sample .shp file of Alaska will appear on the qgis, However you can open and use any gis supported file/project
To deploy newly built qgis container image for ppc64le architecture, navigate to ppc64le-qgis repository
- Logon to OpenShift
$ oc login -u <username> -p <password>
- Create a new project in the OCP -
$ export PROJECT=ppc64le-isv
$ oc new-project $PROJECT
- Update the security constraint, as shown below -
$ oc adm policy add-scc-to-user privileged -z default -n <project name>
$ oc adm policy add-scc-to-user anyuid -z default -n <project name>
- Create the deployment, Update Namespace as project name which you have used in step 2, other fields could be modified if required but not mandatory
$ oc create -f deployment.yaml
- create the service, Update Namespace as project name, again ther fields could be modified if required but not mandatory
$ oc create -f service.yaml
- Expose the qgis service here our qgis service name is qgis-service
$ oc expose service qgis-service
- Query the route
$ oc get route
- The route name will have host/port filed which is the link to access the noVNC client For example
$ oc get route
NAME HOST/PORT PATH SERVICES PORT TERMINATION WILDCARD
qgis-service qgis-service-mithunhr.apps.p1258.cecc.ihost.com qgis-service 6080 None
qgis-service-mithunhr.apps.p1258.cecc.ihost.com
Is your route to access the application.
- Navigate via web browser, click the route as shown in Step 8
-
Click to connect
-
Enter password for VNC - here it is TestVNC
- you would see a sample map of Alaska loaded , You can open and work on any supported QGIS project or file
Maintainers of these sample dockerfile and script
Krishna Harsha Voora @krishvoor
Mithun H R @mithunhr87
Sahitya Jain @Sahityakrj