Skip to content

Commit

Permalink
[MOD] Map Server Ubuntu Server 14.04 -> 18.04 \n ref: bmwcarit#142
Browse files Browse the repository at this point in the history
  • Loading branch information
meenzoon committed Jun 25, 2024
1 parent 97f1c03 commit 330ace8
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 10 deletions.
10 changes: 6 additions & 4 deletions map/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,14 @@
# language governing permissions and limitations under the License.
#

FROM ubuntu:14.04
FROM ubuntu:18.04

MAINTAINER [email protected]

ADD /pgsql/ /opt/pgsql/
RUN apt-get update && apt-get -y install patch postgresql-9.3-postgis-2.1 git openjdk-7-jdk python-psycopg2 python-numpy python-gdal
RUN patch /etc/postgresql/9.3/main/postgresql.conf < /opt/pgsql/postgresql.conf.patch && patch /etc/postgresql/9.3/main/pg_hba.conf < /opt/pgsql/pg_hba.conf.patch && echo "export HOME=/root" >> /root/.bashrc
RUN cd /opt/ && git clone https://github.com/openstreetmap/osmosis.git && cd osmosis && git checkout tags/0.43.1 && ./gradlew assemble && echo "export PATH=${PATH}:/opt/osmosis/package/bin" >> /root/.bashrc
ADD setup_tz.sh /usr/bin/setup_tz.sh
RUN /usr/bin/setup_tz.sh
RUN apt-get -y install sudo patch postgresql-10-postgis-2.4 git openjdk-8-jdk-headless python-psycopg2 python-numpy python-gdal
RUN patch /etc/postgresql/10/main/postgresql.conf < /opt/pgsql/postgresql.conf.patch && patch /etc/postgresql/10/main/pg_hba.conf < /opt/pgsql/pg_hba.conf.patch && echo "export HOME=/root" >> /root/.bashrc
RUN cd /opt/ && git clone https://github.com/openstreetmap/osmosis.git && cd osmosis && git checkout tags/0.47 && ./gradlew assemble && echo "export PATH=${PATH}:/opt/osmosis/package/bin" >> /root/.bashrc
CMD service postgresql start && /bin/bash --rcfile /root/.bashrc
12 changes: 6 additions & 6 deletions map/pgsql/pg_hba.conf.patch
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
--- /etc/postgresql/9.3/main/pg_hba.conf.original 2014-10-25 19:55:37.469260394 +0000
+++ /etc/postgresql/9.3/main/pg_hba.conf 2014-10-25 20:13:38.676594184 +0000
--- pg_hba.conf 2020-02-25 13:41:54.406030860 -0500
+++ pg_hba.conf.edited 2020-02-25 14:12:28.157052052 -0500
@@ -97,3 +97,4 @@
#local replication postgres peer
#host replication postgres 127.0.0.1/32 md5
#host replication postgres ::1/128 md5
+host all all samenet md5
local replication all peer
host replication all 127.0.0.1/32 md5
host replication all ::1/128 md5
+host all all 0.0.0.0/0 md5

7 changes: 7 additions & 0 deletions map/setup_tz.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#set noninteractive installation
export DEBIAN_FRONTEND=noninteractive
#install tzdata package
apt-get update && apt-get install -y tzdata
# set your timezone
ln -fs /usr/share/zoneinfo/Asia/Seoul /etc/localtime
dpkg-reconfigure --frontend noninteractive tzdata

0 comments on commit 330ace8

Please sign in to comment.