From b3d5f37432c3f7edeb39967c64e51897cad3e76b Mon Sep 17 00:00:00 2001 From: Markus Neteler Date: Tue, 4 Apr 2023 14:06:46 +0200 Subject: [PATCH 01/13] docker alpine: cleanup and drop Dockerfile_alpine_latest - drop `Dockerfile_alpine_latest` as being unsed - cleanup `Dockerfile` --- .dockerignore | 1 + docker/alpine/Dockerfile | 66 ++----- docker/alpine/Dockerfile_alpine_latest | 238 ------------------------- 3 files changed, 16 insertions(+), 289 deletions(-) delete mode 100644 docker/alpine/Dockerfile_alpine_latest diff --git a/.dockerignore b/.dockerignore index cd5bc1f3572..56c498f8579 100644 --- a/.dockerignore +++ b/.dockerignore @@ -1,5 +1,6 @@ docker !docker/testdata +!docker/alpine/grass_tests.sh .gitignore .github .travis diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index b49101c6045..d7c2f2ee47b 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -9,8 +9,9 @@ LABEL maintainer="neteler@osgeo.org" ARG PYTHON_VERSION=3 # List of packages to be installed (proj-data omitted: 570.04 MB) -ENV PACKAGES="\ +ENV GRASS_RUN_PACKAGES="\ attr \ + build-base \ bash \ bison \ bzip2 \ @@ -19,6 +20,8 @@ ENV PACKAGES="\ fftw \ flex \ freetype \ + g++ \ + gcc \ gdal \ gdal-dev \ gdal-tools \ @@ -32,6 +35,7 @@ ENV PACKAGES="\ libgeotiff \ libjpeg-turbo \ libpng \ + libpq-dev \ libunwind \ make \ musl \ @@ -73,7 +77,7 @@ RUN echo "Install Python";\ # Add the packages RUN echo "Install main packages";\ apk update; \ - apk add --no-cache $PACKAGES + apk add --no-cache $GRASS_RUN_PACKAGES FROM common as build @@ -121,9 +125,6 @@ ENV GRASS_BUILD_PACKAGES="\ cairo-dev \ fftw-dev \ freetype-dev \ - g++ \ - gcc \ - gdal-dev \ geos-dev \ git \ gnutls-dev \ @@ -131,7 +132,6 @@ ENV GRASS_BUILD_PACKAGES="\ libjpeg-turbo-dev \ libpng-dev \ libpq-dev \ - make \ openjpeg-dev \ openblas-dev \ pdal \ @@ -187,39 +187,8 @@ COPY --from=build /usr/local/grass* /usr/local/grass/ # install external Python API RUN pip3 install --upgrade pip six grass-session --ignore-installed six +# TODO: still needed? RUN ln -sf /usr/local/grass $(grass --config path) -RUN grass --tmp-location XY --exec g.version -rge && \ - pdal --version && \ - python3 --version - - -FROM grass as test - -## run simple LAZ test -COPY docker/testdata/simple.laz /tmp/simple.laz -COPY docker/testdata/test_grass_session.py /scripts/test_grass_session.py -ENV GRASSBIN=grass - -# Test grass-session -# Not yet ready for GRASS GIS 8: -RUN /usr/bin/python3 /scripts/test_grass_session.py -# Test PDAL -RUN grass --tmp-location EPSG:25832 --exec r.in.pdal input="/tmp/simple.laz" output="count_1" method="n" resolution=1 -g - -# Test addon installation -RUN apk add --no-cache py3-scikit-learn -RUN grass --tmp-location XY --exec g.extension extension=r.learn.ml2 - - -FROM grass as final - -# These packages are required to run g.extension in GRASS GIS. -ENV GRASS_RUN_PACKAGES="\ - build-base \ - gcc \ - libpq-dev \ - make \ - " # GRASS GIS specific # allow work with MAPSETs that are not owned by current user @@ -230,26 +199,21 @@ ENV GRASSBIN="/usr/local/bin/grass" \ # https://proj.org/usage/environmentvars.html#envvar-PROJ_NETWORK ENV PROJ_NETWORK=ON -# Add packages for fully enabling g.extension -RUN apk add --no-cache $GRASS_RUN_PACKAGES +## run simple LAZ test +COPY docker/testdata/simple.laz /tmp/ +COPY docker/testdata/test_grass_session.py /scripts/ +COPY docker/alpine/grass_tests.sh /scripts/ +ENV GRASSBIN=grass -# addon test in final stage: does g.extension install also C-extensions? -# test raster C addon -RUN grass --tmp-location XY --exec g.extension extension=r.gwr operation=add -RUN grass --tmp-location XY --exec g.extension extension=r.gwr operation=remove -f -# test vector C addon -RUN grass --tmp-location XY --exec g.extension extension=v.centerpoint operation=add -RUN grass --tmp-location XY --exec g.extension extension=v.centerpoint operation=remove -f +# run some tests and cleanup +RUN /bin/bash /scripts/grass_tests.sh && rm -f /scripts/grass_tests.sh \ + /tmp/simple.laz /scripts/test_grass_session.py # show installed version RUN grass --tmp-location XY --exec g.version -rge && \ pdal --version && \ python3 --version -# test r.in.pdal in final image because test stage is not executed in github action -COPY docker/testdata/simple.laz /tmp/simple.laz -RUN grass --tmp-location EPSG:25832 --exec r.in.pdal input="/tmp/simple.laz" output="count_1" method="n" resolution=1 -g - # Data workdir WORKDIR /grassdb VOLUME /grassdb diff --git a/docker/alpine/Dockerfile_alpine_latest b/docker/alpine/Dockerfile_alpine_latest deleted file mode 100644 index f2ab32e99bc..00000000000 --- a/docker/alpine/Dockerfile_alpine_latest +++ /dev/null @@ -1,238 +0,0 @@ -FROM alpine:latest - -# Based on: -# https://github.com/mundialis/docker-grass-gis/blob/master/Dockerfile -LABEL authors="Carmen Tawalika,Pietro Zambelli,Markus Neteler" -LABEL maintainer="neteler@osgeo.org" - -# without PDAL - -# PACKAGES VERSIONS -ARG PYTHON_VERSION=3 - -# ================ -# CONFIG VARIABLES -# ================ - -# set configuration options, without wxGUI -ENV GRASS_CONFIG="\ - --enable-largefile \ - --with-cxx \ - --with-proj-share=/usr/share/proj \ - --with-gdal \ - --with-geos \ - --with-sqlite \ - --with-bzlib \ - --with-zstd \ - --with-cairo --with-cairo-ldflags=-lfontconfig \ - --with-fftw \ - --with-postgres --with-postgres-includes=/usr/include/postgresql \ - --without-freetype \ - --without-pdal \ - --without-openmp \ - --without-opengl \ - --without-nls \ - --without-mysql \ - --without-odbc \ - " - -# Set environmental variables for GRASS GIS compilation, without debug symbols -ENV MYCFLAGS="-O2 -std=gnu99 -m64" \ - MYLDFLAGS="-s -Wl,--no-undefined -lblas" \ - # CXX stuff: - LD_LIBRARY_PATH="/usr/local/lib" \ - LDFLAGS="$MYLDFLAGS" \ - CFLAGS="$MYCFLAGS" \ - CXXFLAGS="$MYCXXFLAGS" \ - NUMTHREADS=2 - - -# List of packages to be installed (proj-data omitted: 570.04 MB) -ENV PACKAGES="\ - attr \ - build-base \ - make \ - bash \ - bison \ - bzip2 \ - cairo \ - fftw \ - flex \ - freetype \ - g++ \ - gcc \ - gdal-dev \ - geos-dev \ - gettext \ - geos \ - gnutls \ - libbz2 \ - libjpeg-turbo \ - libpng \ - libpq-dev \ - make \ - musl \ - musl-utils \ - ncurses \ - openjpeg \ - openblas \ - py3-numpy \ - py3-pillow \ - py3-six \ - postgresql \ - proj-util \ - sqlite \ - sqlite-libs \ - subversion \ - tiff \ - zstd \ - zstd-libs \ - " \ - # These packages are required to compile GRASS GIS. - GRASS_BUILD_PACKAGES="\ - bzip2-dev \ - cairo-dev \ - fftw-dev \ - freetype-dev \ - git \ - gnutls-dev \ - libc6-compat \ - libjpeg-turbo-dev \ - libpng-dev \ - openjpeg-dev \ - openblas-dev \ - proj-dev \ - python3-dev \ - py3-numpy-dev \ - sqlite-dev \ - tar \ - tiff-dev \ - unzip \ - vim \ - wget \ - zip \ - zstd-dev \ - " - -# ==================== -# INSTALL DEPENDENCIES -# ==================== - -WORKDIR /src - -ENV PYTHONBIN=python$PYTHON_VERSION - -RUN echo "Install Python";\ - apk add --no-cache $PYTHONBIN && \ - $PYTHONBIN -m ensurepip && \ - rm -r /usr/lib/python*/ensurepip && \ - pip$PYTHON_VERSION install --upgrade pip setuptools && \ - if [ ! -e /usr/bin/pip ]; then ln -s pip$PYTHON_VERSION /usr/bin/pip ; fi && \ - if [ ! -e /usr/bin/python ]; then ln -sf /usr/bin/$PYTHONBIN /usr/bin/python; fi && \ - rm -r /root/.cache - -# Add the packages -RUN echo "Install main packages";\ - apk update; \ - apk add --no-cache \ - --repository http://dl-cdn.alpinelinux.org/alpine/latest-stable/main \ - $PACKAGES; \ - # Add packages just for the GRASS build process - apk add --no-cache \ - --repository http://dl-cdn.alpinelinux.org/alpine/latest-stable/main \ - --virtual .build-deps $GRASS_BUILD_PACKAGES; \ - # echo LANG="en_US.UTF-8" > /etc/default/locale; - # - # Checkout and install GRASS GIS - # - echo "Install GRASS GIS";\ - echo " => Downloading grass" - -COPY . /src/grass_build/ - -# Configure compile and install GRASS GIS -RUN echo " => Configure and compile grass";\ - cd /src/grass_build && \ - /src/grass_build/configure $GRASS_CONFIG && \ - make -j $NUMTHREADS && \ - make install && \ - ldconfig /etc/ld.so.conf.d; \ - # - # Reduce the image size - # - rm -rf /src/*; \ - # remove build dependencies and any leftover apk cache - apk del --no-cache --purge .build-deps; \ - rm -rf /var/cache/apk/*; \ - rm -rf /root/.cache; \ - # Remove unnecessary grass files - rm -rf /usr/local/grass83/demolocation; \ - rm -rf /usr/local/grass83/fonts; \ - rm -rf /usr/local/grass83/gui; \ - rm -rf /usr/local/grass83/share; - - -# Unset environmental variables to avoid later compilation issues -ENV INTEL="" \ - MYCFLAGS="" \ - MYLDFLAGS="" \ - MYCXXFLAGS="" \ - LD_LIBRARY_PATH="" \ - LDFLAGS="" \ - CFLAGS="" \ - CXXFLAGS="" \ - # set SHELL var to avoid /bin/sh fallback in interactive GRASS GIS sessions in docker - SHELL="/bin/bash" - - -# ===================== -# INSTALL GRASS-SESSION -# ===================== - -# install external Python API -RUN pip install grass-session - -# set GRASSBIN -ENV GRASSBIN="/usr/local/bin/grass" - -# ================== -# TEST grass-session -# ================== - -WORKDIR /scripts -COPY docker/testdata/test_grass_session.py . -# TODO: fix test -#RUN /usr/bin/python3 /scripts/test_grass_session.py - -# ======== -# FINALIZE -# ======== - -# GRASS GIS specific -# allow work with MAPSETs that are not owned by current user -ENV GRASS_SKIP_MAPSET_OWNER_CHECK=1 \ - LC_ALL="en_US.UTF-8" - -# https://proj.org/usage/environmentvars.html#envvar-PROJ_NETWORK -ENV PROJ_NETWORK=ON - -# Add packages for fully enabling g.extension -RUN apk add --no-cache $GRASS_RUN_PACKAGES - -# addon test in final stage: does g.extension install also C-extensions? -# test raster C addon -RUN grass --tmp-location XY --exec g.extension extension=r.gwr operation=add -RUN grass --tmp-location XY --exec g.extension extension=r.gwr operation=remove -f -# test vector C addon -RUN grass --tmp-location XY --exec g.extension extension=v.centerpoint operation=add -RUN grass --tmp-location XY --exec g.extension extension=v.centerpoint operation=remove -f - -# show installed version -RUN grass --tmp-location XY --exec g.version -rge && \ - python3 --version - -# Data workdir -WORKDIR /grassdb -VOLUME /grassdb - -CMD ["$GRASSBIN", "--version"] From 52b4f17a1faabedeef9fd3554f757734aef9f62b Mon Sep 17 00:00:00 2001 From: Markus Neteler Date: Tue, 4 Apr 2023 16:47:24 +0200 Subject: [PATCH 02/13] drop gettext, pdal-dev from final image --- docker/alpine/Dockerfile | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index d7c2f2ee47b..888665f5e8b 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -209,6 +209,9 @@ ENV GRASSBIN=grass RUN /bin/bash /scripts/grass_tests.sh && rm -f /scripts/grass_tests.sh \ /tmp/simple.laz /scripts/test_grass_session.py +# delete unused packages +RUN apk del --no-cache gettext pdal-dev + # show installed version RUN grass --tmp-location XY --exec g.version -rge && \ pdal --version && \ From e1f2fd176ae58be05bcfc3e3e55f60462a8e9b0c Mon Sep 17 00:00:00 2001 From: Markus Neteler Date: Sun, 16 Apr 2023 22:03:30 +0200 Subject: [PATCH 03/13] add missing test file docker/alpine/grass_tests.sh --- docker/alpine/grass_tests.sh | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 docker/alpine/grass_tests.sh diff --git a/docker/alpine/grass_tests.sh b/docker/alpine/grass_tests.sh new file mode 100644 index 00000000000..54d7b898f43 --- /dev/null +++ b/docker/alpine/grass_tests.sh @@ -0,0 +1,24 @@ +#/bin/bash + +# to be used in alpine Dockerfile + +# add dependency +apk add --no-cache py3-scikit-learn + +# Test grass-session (not yet ready for GRASS GIS 8): +/usr/bin/python3 /scripts/test_grass_session.py +# Test PDAL +grass --tmp-location EPSG:25832 --exec r.in.pdal input="/tmp/simple.laz" output="count_1" method="n" resolution=1 -g + +# Test GRASS GIS Python-addon installation +grass --tmp-location XY --exec g.extension extension=r.learn.ml2 operation=add && \ + grass --tmp-location XY --exec g.extension extension=r.learn.ml2 operation=remove -f + +# Test GRASS GIS C-addon installation: raster and vector +grass --tmp-location XY --exec g.extension extension=r.gwr operation=add && \ + grass --tmp-location XY --exec g.extension extension=r.gwr operation=remove -f +grass --tmp-location XY --exec g.extension extension=v.centerpoint operation=add && \ + grass --tmp-location XY --exec g.extension extension=v.centerpoint operation=remove -f + +# cleanup dependency +apk del py3-scikit-learn From 4bca1e53da5376efb451b6743fee005bac8ad11a Mon Sep 17 00:00:00 2001 From: Markus Neteler Date: Mon, 17 Apr 2023 10:15:19 +0200 Subject: [PATCH 04/13] fix ERROR: 'git' required --- docker/alpine/Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index 888665f5e8b..d11bdd84b1e 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -28,6 +28,7 @@ ENV GRASS_RUN_PACKAGES="\ gettext \ geos \ geos-dev \ + git \ gnutls \ jsoncpp \ laszip \ From fbd13a01bbace635512f9c958bab66c1b962c350 Mon Sep 17 00:00:00 2001 From: Markus Neteler Date: Tue, 18 Apr 2023 11:07:11 +0200 Subject: [PATCH 05/13] fixed grass-session test in docker/testdata/test_grass_session.py --- docker/alpine/grass_tests.sh | 2 +- docker/testdata/test_grass_session.py | 9 +++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/docker/alpine/grass_tests.sh b/docker/alpine/grass_tests.sh index 54d7b898f43..bf25d54355b 100644 --- a/docker/alpine/grass_tests.sh +++ b/docker/alpine/grass_tests.sh @@ -5,7 +5,7 @@ # add dependency apk add --no-cache py3-scikit-learn -# Test grass-session (not yet ready for GRASS GIS 8): +# Test grass-session: /usr/bin/python3 /scripts/test_grass_session.py # Test PDAL grass --tmp-location EPSG:25832 --exec r.in.pdal input="/tmp/simple.laz" output="count_1" method="n" resolution=1 -g diff --git a/docker/testdata/test_grass_session.py b/docker/testdata/test_grass_session.py index e7d3b6d2930..84d55d36eaf 100644 --- a/docker/testdata/test_grass_session.py +++ b/docker/testdata/test_grass_session.py @@ -4,10 +4,15 @@ from grass_session import Session import grass.script as gs +# hint: do not use ~ as an alias for HOME with Session( - gisdb="/grassdata/", location="test", mapset="PERMANENT", create_opts="EPSG:25832" + # run in PERMANENT mapset after creation of location "test" + gisdb="/grassdata/", + location="test", + create_opts="EPSG:25832", ): - print("Tests for PROJ, GDAL, PDAL, GRASS") + print("grass-session: tests for PROJ, GDAL, PDAL, GRASS GIS") + print(gs.parse_command("g.gisenv", flags="s")) # simple test: just scan the LAZ file gs.run_command( From 69d74c96e12f38c073c4b4eed21c43acb9a0f9f8 Mon Sep 17 00:00:00 2001 From: Markus Neteler Date: Tue, 18 Apr 2023 11:10:54 +0200 Subject: [PATCH 06/13] mention pip --- docker/testdata/test_grass_session.py | 1 + 1 file changed, 1 insertion(+) diff --git a/docker/testdata/test_grass_session.py b/docker/testdata/test_grass_session.py index 84d55d36eaf..70cce197305 100644 --- a/docker/testdata/test_grass_session.py +++ b/docker/testdata/test_grass_session.py @@ -1,5 +1,6 @@ # Import GRASS Python bindings # https://github.com/zarch/grass-session +# pip install grass-session from grass_session import Session import grass.script as gs From d88c66d64037c7de38cced80d5db5f7e2272da54 Mon Sep 17 00:00:00 2001 From: Tomas Zigo Date: Thu, 20 Apr 2023 14:35:30 +0200 Subject: [PATCH 07/13] group some Dockerfile layers --- docker/alpine/Dockerfile | 61 +++++++++++++++++----------------------- 1 file changed, 26 insertions(+), 35 deletions(-) diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index d11bdd84b1e..c3d010037d5 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -73,10 +73,9 @@ RUN echo "Install Python";\ pip$PYTHON_VERSION install --upgrade pip setuptools && \ if [ ! -e /usr/bin/pip ]; then ln -s pip$PYTHON_VERSION /usr/bin/pip ; fi && \ if [ ! -e /usr/bin/python ]; then ln -sf /usr/bin/$PYTHONBIN /usr/bin/python; fi && \ - rm -r /root/.cache - -# Add the packages -RUN echo "Install main packages";\ + rm -r /root/.cache; \ + # Add the packages + echo "Install main packages";\ apk update; \ apk add --no-cache $GRASS_RUN_PACKAGES @@ -179,47 +178,39 @@ RUN cp /usr/local/grass83/gui/wxpython/xml/module_items.xml module_items.xml; \ FROM common as grass -ENV LC_ALL="en_US.UTF-8" - -# Copy GRASS GIS from build image -COPY --from=build /usr/local/bin/grass /usr/local/bin/grass -COPY --from=build /usr/local/grass* /usr/local/grass/ - -# install external Python API -RUN pip3 install --upgrade pip six grass-session --ignore-installed six - -# TODO: still needed? -RUN ln -sf /usr/local/grass $(grass --config path) - # GRASS GIS specific # allow work with MAPSETs that are not owned by current user ENV GRASSBIN="/usr/local/bin/grass" \ GRASS_SKIP_MAPSET_OWNER_CHECK=1 \ - SHELL="/bin/bash" - -# https://proj.org/usage/environmentvars.html#envvar-PROJ_NETWORK -ENV PROJ_NETWORK=ON + SHELL="/bin/bash" \ + # https://proj.org/usage/environmentvars.html#envvar-PROJ_NETWORK + PROJ_NETWORK=ON \ + GRASSBIN=grass \ + LC_ALL="en_US.UTF-8" -## run simple LAZ test +# Copy GRASS GIS from build image +COPY --from=build /usr/local/bin/grass /usr/local/bin/grass +COPY --from=build /usr/local/grass* /usr/local/grass/ +# run simple LAZ test COPY docker/testdata/simple.laz /tmp/ +COPY docker/testdata/test_grass_session.py docker/alpine/grass_tests.sh /scripts/ COPY docker/testdata/test_grass_session.py /scripts/ -COPY docker/alpine/grass_tests.sh /scripts/ -ENV GRASSBIN=grass - -# run some tests and cleanup -RUN /bin/bash /scripts/grass_tests.sh && rm -f /scripts/grass_tests.sh \ - /tmp/simple.laz /scripts/test_grass_session.py -# delete unused packages -RUN apk del --no-cache gettext pdal-dev - -# show installed version -RUN grass --tmp-location XY --exec g.version -rge && \ - pdal --version && \ - python3 --version +# install external Python API +RUN pip3 install --upgrade pip six grass-session --ignore-installed six; \ + ln -sf /usr/local/grass $(grass --config path); \ + # run some tests and cleanup + $SHELL /scripts/grass_tests.sh \ + && rm -f /scripts/grass_tests.sh /tmp/simple.laz /scripts/test_grass_session.py; \ + # delete unused packages + apk del --no-cache gettext pdal-dev; \ + # show installed version + grass --tmp-location XY --exec g.version -rge \ + && pdal --version \ + && python3 --version # Data workdir WORKDIR /grassdb VOLUME /grassdb -CMD ["$GRASSBIN", "--version"] +CMD ["$GRASSBIN", "--version"] \ No newline at end of file From 953320efc3b25a7540c06584876a729c51e4ce6b Mon Sep 17 00:00:00 2001 From: Tomas Zigo Date: Thu, 20 Apr 2023 14:39:39 +0200 Subject: [PATCH 08/13] remove dev packages from the list of runtime packages --- docker/alpine/Dockerfile | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index c3d010037d5..ce89989ede1 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -23,11 +23,9 @@ ENV GRASS_RUN_PACKAGES="\ g++ \ gcc \ gdal \ - gdal-dev \ gdal-tools \ gettext \ geos \ - geos-dev \ git \ gnutls \ jsoncpp \ @@ -36,7 +34,6 @@ ENV GRASS_RUN_PACKAGES="\ libgeotiff \ libjpeg-turbo \ libpng \ - libpq-dev \ libunwind \ make \ musl \ @@ -48,7 +45,6 @@ ENV GRASS_RUN_PACKAGES="\ py3-pillow \ py3-six \ pdal \ - pdal-dev \ postgresql \ proj-util \ sqlite \ @@ -203,7 +199,7 @@ RUN pip3 install --upgrade pip six grass-session --ignore-installed six; \ $SHELL /scripts/grass_tests.sh \ && rm -f /scripts/grass_tests.sh /tmp/simple.laz /scripts/test_grass_session.py; \ # delete unused packages - apk del --no-cache gettext pdal-dev; \ + apk del --no-cache gettext; \ # show installed version grass --tmp-location XY --exec g.version -rge \ && pdal --version \ From da54b175ab8415b36d939efe8ec219f6d5909fb9 Mon Sep 17 00:00:00 2001 From: Tomas Zigo Date: Thu, 20 Apr 2023 14:40:20 +0200 Subject: [PATCH 09/13] add 'gdal-dev' dev package into list of the dev packages --- docker/alpine/Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index ce89989ede1..26159c46791 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -143,6 +143,7 @@ ENV GRASS_BUILD_PACKAGES="\ wget \ zip \ zstd-dev \ + gdal-dev \ " # Add the packages From a932d6bc2e46466e1e4014d1a5df8a414bcee217 Mon Sep 17 00:00:00 2001 From: Tomas Zigo Date: Thu, 20 Apr 2023 16:12:13 +0200 Subject: [PATCH 10/13] Add newline on the end of the Dockerfile --- docker/alpine/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index 26159c46791..ea1a2dab7fb 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -210,4 +210,4 @@ RUN pip3 install --upgrade pip six grass-session --ignore-installed six; \ WORKDIR /grassdb VOLUME /grassdb -CMD ["$GRASSBIN", "--version"] \ No newline at end of file +CMD ["$GRASSBIN", "--version"] From 0737b9786b3a0ae25e44773fab592118dee91405 Mon Sep 17 00:00:00 2001 From: Tomas Zigo Date: Fri, 21 Apr 2023 06:56:41 +0200 Subject: [PATCH 11/13] Revert "remove dev packages from the list of runtime packages" This reverts commit 953320efc3b25a7540c06584876a729c51e4ce6b. These dev packages is required for installation/compilation v.centerpoint addon. --- docker/alpine/Dockerfile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index ea1a2dab7fb..e742b4edda1 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -23,9 +23,11 @@ ENV GRASS_RUN_PACKAGES="\ g++ \ gcc \ gdal \ + gdal-dev \ gdal-tools \ gettext \ geos \ + geos-dev \ git \ gnutls \ jsoncpp \ @@ -34,6 +36,7 @@ ENV GRASS_RUN_PACKAGES="\ libgeotiff \ libjpeg-turbo \ libpng \ + libpq-dev \ libunwind \ make \ musl \ @@ -45,6 +48,7 @@ ENV GRASS_RUN_PACKAGES="\ py3-pillow \ py3-six \ pdal \ + pdal-dev \ postgresql \ proj-util \ sqlite \ @@ -200,7 +204,7 @@ RUN pip3 install --upgrade pip six grass-session --ignore-installed six; \ $SHELL /scripts/grass_tests.sh \ && rm -f /scripts/grass_tests.sh /tmp/simple.laz /scripts/test_grass_session.py; \ # delete unused packages - apk del --no-cache gettext; \ + apk del --no-cache gettext pdal-dev; \ # show installed version grass --tmp-location XY --exec g.version -rge \ && pdal --version \ From 51f2540f42642b482a1b726d9b6e4692b301ef11 Mon Sep 17 00:00:00 2001 From: Tomas Zigo Date: Fri, 21 Apr 2023 06:58:35 +0200 Subject: [PATCH 12/13] Revert "add 'gdal-dev' dev package into list of the dev packages" This reverts commit da54b175ab8415b36d939efe8ec219f6d5909fb9. --- docker/alpine/Dockerfile | 1 - 1 file changed, 1 deletion(-) diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index e742b4edda1..88e4f0ed239 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -147,7 +147,6 @@ ENV GRASS_BUILD_PACKAGES="\ wget \ zip \ zstd-dev \ - gdal-dev \ " # Add the packages From 6b171f01adedcf28acfaeb485fc54da2bc4fbcd9 Mon Sep 17 00:00:00 2001 From: Tomas Zigo Date: Fri, 21 Apr 2023 07:01:08 +0200 Subject: [PATCH 13/13] For the GRASS GIS runtime, the postgresql15-client package is sufficient --- docker/alpine/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/alpine/Dockerfile b/docker/alpine/Dockerfile index 88e4f0ed239..ed900b11358 100644 --- a/docker/alpine/Dockerfile +++ b/docker/alpine/Dockerfile @@ -49,7 +49,7 @@ ENV GRASS_RUN_PACKAGES="\ py3-six \ pdal \ pdal-dev \ - postgresql \ + postgresql15-client \ proj-util \ sqlite \ sqlite-libs \