From 733dc7144704c372da6e8dbef2db9fe08fa106d0 Mon Sep 17 00:00:00 2001 From: skylerbunny Date: Thu, 9 Aug 2018 04:41:29 -0700 Subject: [PATCH] Update kosmtik, db, import Dockerfiles for Ubuntu 18.04 and nodejs 8 (#3310) --- Dockerfile | 19 +++++++------------ Dockerfile.db | 2 +- Dockerfile.import | 12 +++++++----- 3 files changed, 15 insertions(+), 18 deletions(-) diff --git a/Dockerfile b/Dockerfile index 8e35a08ade..7eb830f702 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,19 +1,14 @@ -FROM ubuntu:xenial +FROM ubuntu:bionic # Style dependencies RUN apt-get update && apt-get install --no-install-recommends -y \ - unzip curl ca-certificates gnupg python postgresql-client \ - fonts-noto-cjk fonts-noto-hinted fonts-noto-unhinted ttf-unifont \ - mapnik-utils \ - && rm -rf /var/lib/apt/lists/* + ca-certificates curl gnupg postgresql-client python fonts-hanazono \ + fonts-noto-cjk fonts-noto-hinted fonts-noto-unhinted mapnik-utils \ + nodejs npm ttf-unifont unzip && rm -rf /var/lib/apt/lists/* -# Node.js 6.x LTS -RUN curl -sL https://deb.nodesource.com/setup_6.x | bash \ - && apt-get install --no-install-recommends -y nodejs \ - && rm -rf /var/lib/apt/lists/* - -# Kosmtik with plugins -RUN npm install -g kosmtik +# Kosmtik with plugins, forcing prefix to /usr because bionic sets +# npm prefix to /usr/local, which breaks the install +RUN npm set prefix /usr && npm install -g kosmtik WORKDIR /usr/lib/node_modules/kosmtik/ RUN kosmtik plugins --install kosmtik-overpass-layer \ diff --git a/Dockerfile.db b/Dockerfile.db index 63c312a662..649f907669 100644 --- a/Dockerfile.db +++ b/Dockerfile.db @@ -1,3 +1,3 @@ -FROM mdillon/postgis:9.6 +FROM mdillon/postgis:10 ADD ./scripts/tune-postgis.sh /docker-entrypoint-initdb.d diff --git a/Dockerfile.import b/Dockerfile.import index bc46c03914..0ed43dc47c 100644 --- a/Dockerfile.import +++ b/Dockerfile.import @@ -1,15 +1,17 @@ -FROM ubuntu:xenial +FROM ubuntu:bionic -RUN echo 'deb http://ppa.launchpad.net/osmadmins/ppa/ubuntu xenial main\n\ -deb-src http://ppa.launchpad.net/osmadmins/ppa/ubuntu xenial main' > \ +RUN apt-get update && apt-get install --no-install-recommends -y \ + ca-certificates curl gnupg && rm -rf /var/lib/apt/lists/* + +RUN echo 'deb http://ppa.launchpad.net/osmadmins/ppa/ubuntu bionic main\n\ +deb-src http://ppa.launchpad.net/osmadmins/ppa/ubuntu bionic main' > \ /etc/apt/sources.list.d/osmadmins-ppa.list RUN apt-key adv --keyserver keyserver.ubuntu.com \ --recv A438A16C88C6BE41CB1616B8D57F48750AC4F2CB RUN apt-get update && apt-get install --no-install-recommends -y \ - curl ca-certificates osm2pgsql postgresql-client \ - && rm -rf /var/lib/apt/lists/* + osm2pgsql postgresql-client && rm -rf /var/lib/apt/lists/* ADD openstreetmap-carto.style /