comparison docker/Dockerfile.mapserv @ 9734:95496d21b4da 3.2.x

Add MapServer to Docker setup
author Tom Gottfried <tom@intevation.de>
date Fri, 22 Jul 2022 17:56:11 +0200
parents
children 68c6fe74a276
comparison
equal deleted inserted replaced
9733:93b9034613bc 9734:95496d21b4da
1 # Docker file for D4E River MapServer
2 # with support for PostgreSQL and Oracle databases
3
4 FROM centos:7
5 MAINTAINER tom@intevation.de
6
7 # Necessary to run further yum-installs inside Docker container,
8 # if not already part of the base image:
9 RUN yum -q -y install yum-plugin-ovl && rpm --rebuilddb
10
11 # Install prerequisites
12 RUN yum -q -y install curl ca-certificates epel-release \
13 gnu-free-sans-fonts httpd
14 RUN yum -q -y install gcc-c++ postgresql-devel gd-devel giflib-devel proj-devel \
15 proj-epsg prelink make
16
17 # Install Oracle client
18 RUN curl -s https://yum.oracle.com/RPM-GPG-KEY-oracle-ol7 \
19 -o /etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
20 ADD ol7-temp.repo /etc/yum.repos.d/
21 RUN yum -q -y install oraclelinux-release-el7
22 RUN mv /etc/yum.repos.d/ol7-temp.repo /etc/yum.repos.d/ol7-temp.repo.disabled
23 RUN yum -q -y install oracle-release-el7
24 RUN yum -q -y install oracle-instantclient19.9-basic \
25 oracle-instantclient19.9-devel
26 RUN yum-config-manager --disable oracle*,ol7*
27
28 # Install MapServer
29 WORKDIR /opt/mapserver
30 RUN curl -s https://download.osgeo.org/mapserver/mapserver-6.0.6.tar.gz | tar xz
31 WORKDIR mapserver-6.0.6
32 RUN sed -i "s@oracle/10\*/client@oracle/19.9/client64@g" configure
33 RUN ./configure -q --with-proj --with-postgis --with-oraclespatial=/usr \
34 CFLAGS=-w CXXFLAGS=-w
35 RUN make -s
36 WORKDIR /opt/mapserver
37 RUN ln -s mapserver-6.0.6/mapserv
38
39 # Volume to share mapfiles with artifact server.
40 # Has to be the same path as in artifact server container because mapfiles
41 # contain absolute paths.
42 VOLUME /opt/d4e/bin
43
44 # CGI scripts
45 ADD river-wms /var/www/cgi-bin/
46 ADD user-wms /var/www/cgi-bin/
47
48 # httpd config
49 ADD httpd-mapserver.conf /etc/httpd/conf.d/
50
51 EXPOSE 80
52 CMD ["/usr/sbin/httpd", "-DFOREGROUND"]

http://dive4elements.wald.intevation.org