In order to simplify the installation of the latest PDAL release (Point Data Abstraction Library, https://www.pdal.io/, version 1.6.0) on Fedora, I have created an updated set of RPM packages now including vertical datums and grids (.gtx files from here).
The installation is as simple as this (the repository is located at Fedora’s COPR):
https://neteler.org/wp-content/uploads/2024/01/wg_neteler_logo.png00Markushttps://neteler.org/wp-content/uploads/2024/01/wg_neteler_logo.pngMarkus2017-11-03 11:39:462023-10-22 18:58:47PDAL 1.6.0 packaged for Fedora including vertical datums and grids
Thanks to the work of Volker Fröhlich and other Fedora/EPEL packagers I was able to create RPM packages of QGIS 2.10 Pisa for Fedora 21, Centos 7, and Scientific Linux 7 using the great COPR platform.
Sometimes, we developers get reports via mailing list that this & that would not work on whatever operating system. Now what? Should we be so kind and install the operating system in question in order to reproduce the problem? Too much work… but nowadays it has become much easier to perform such tests without having the need to install a full virtual machine – thanks to docker.
Disclaimer: I don’t know much about docker yet, so take the code below with a grain of salt!
In my case I usually work on Fedora or Scientific Linux based systems. In order to quickly (i.e. roughly 10 min of automated installation on my slow laptop) try out issues of GRASS GIS 7 on e.g., Ubuntu, I can run all my tests in docker installed on my Fedora box:
# we need to run stuff as root user
su
# Fedora 21: install docker
yum -y docker-io
# Fedora 22: install docker
dnf -y install docker
# enable service
systemctl start docker
systemctl enable docker
Now we have a running docker environment. Since we want to exchange data (e.g. GIS data) with the docker container later, we prepare a shared directory beforehand:
# we'll later map /home/neteler/data/docker_tmp to /tmp within the docker container
mkdir /home/neteler/data/docker_tmp
Now we can start to install a Ubuntu docker image (may be “any” image, here we use “Ubuntu trusty” in our example). We will share the X11 display in order to be able to use the GUI as well:
# enable X11 forwarding
xhost +local:docker
# search for available docker images
docker search trusty
# fetch docker image from internet, establish shared directory and display redirect
# and launch the container along with a shell
docker run -v /data/docker_tmp:/tmp:rw -v /tmp/.X11-unix:/tmp/.X11-unix \
-e uid=$(id -u) -e gid=$(id -g) -e DISPLAY=unix$DISPLAY \
--name grass70trusty -i -t corbinu/docker-trusty /bin/bash
In almost no time we reach the command line of this minimalistic Ubuntu container which will carry the name “grass70trusty” in our case (btw: read more about Working with Docker Images):
root@8e0f233c3d68:/#
# now we register the Ubuntu-GIS repos and get GRASS GIS 7.0
add-apt-repository ppa:ubuntugis/ubuntugis-unstable
add-apt-repository ppa:grass/grass-stable
apt-get update
apt-get install grass7
This will take a while (the remaining 9 minutes or so of the overall 10 minutes).
Since I like cursor support on the command line, I launch (again?) the bash in the container session:
root@8e0f233c3d68:/# bash
# yes, we are in Ubuntu here
root@8e0f233c3d68:/# cat /etc/issue
Now we can start to use GRASS GIS 7, even with its graphical user interface from inside the docker container:
# create a directory for our data, it is mapped to /home/neteler/data/docker_tmp/
# on the host machine
root@8e0f233c3d68:/# mkdir /tmp/grassdata
# create a new LatLong location from EPSG code
# (or copy a location into /home/neteler/data/docker_tmp/)
root@8e0f233c3d68:/# grass70 -c epsg:4326 ~/grassdata/latlong_wgs84
# generate some data to play with
root@8e0f233c3d68:/# v.random n=30 output=random30
# start the GUI manually (since we didn't start GRASS GIS right away with it before)
root@8e0f233c3d68:/# g.gui
Indeed, the GUI comes up as expected!
GRASS GIS 7 GUI in docker container
You may now perform all tests, bugfixes, whatever you like and leave the GRASS GIS session as usual.
To get out of the docker session:
root@8e0f233c3d68:/# exit # leave the extra bash shell
root@8e0f233c3d68:/# exit # leave docker session
# disable docker connections to the X server
[root@oboe neteler]# xhost -local:docker
To restart this session later again, you will call it with the name which we have earlier assigned:
[root@oboe neteler]# docker ps -a
# ... you should see "grass70trusty" in the output in the right column
# we are lazy and automate the start a bit
[root@oboe neteler]# GRASSDOCKER_ID=`docker ps -a | grep grass70trusty | cut -d' ' -f1`
[root@oboe neteler]# echo $GRASSDOCKER_ID
[root@oboe neteler]# xhost +local:docker
[root@oboe neteler]# docker start -a -i $GRASSDOCKER_ID
### ... and so on as described above.
https://neteler.org/wp-content/uploads/2024/01/wg_neteler_logo.png00Markushttps://neteler.org/wp-content/uploads/2024/01/wg_neteler_logo.pngMarkus2015-04-12 00:30:102023-11-11 19:07:57Fun with docker and GRASS GIS software
Thanks to the work of Devrim Gündüz, Volker Fröhlich, Dave Johansen, Rex Dieter and other Fedora/EPEL packagers I had an easy going to prepare RPM packages of QGIS 2.8 Wien for Fedora 20 and 21, Centos 7, and Scientific Linux 7.
The base SRPM package I copied from Fedora’s koji server, modified the SPEC file in order to remove the now outdated PyQwt bindings (see bugzilla) and compiled QGIS 2.8 via the great COPR platform.
Thanks to Volker Fröhlich’s efforts, a source code RPM package (SRPM) of QGIS 2.0.1 is now available for Fedora. If you are not yet F20 user (like me), you can just take the F20 package and compile it for F19 (or even F18) since there will be no backport of QGIS 2 to F19 (it comes with QGIS 1.8). But: we do want QGIS 2 on Fedora19!
Solution: compile it yourself.
1. Preparations
The best way is to use “mock” which is used to recompile SRPMS in a separate local environment (“chroot”) without cluttering the system with extra packages needed for the compilation (run as “root”):
Once the compilation job is done, i.e. the binary RPM files are available for installation. To install the freshly compiled QGIS 2.0.1 RPMs, run:
cd /var/lib/mock/fedora-19-x86_64/result/
# an existing QGIS1.8 installation will be replaced:
yum localinstall qgis-2.0.1-2.fc19.x86_64.rpm \
qgis-grass-2.0.1-2.fc19.x86_64.rpm qgis-python-2.0.1-2.fc19.x86_64.rpm
# consider to cleanup (or keep it for the next update, it is about 1.5GB):
rm -rf /var/lib/mock/fedora-19-x86_64/
# leave the "root" shell
exit
https://neteler.org/wp-content/uploads/2024/01/wg_neteler_logo.png00Markushttps://neteler.org/wp-content/uploads/2024/01/wg_neteler_logo.pngMarkus2013-09-28 22:59:002023-11-11 21:35:11Compiling QGIS 2.0.1 for Fedora 19 in a few steps