Skip to content

Commit

Permalink
Docker: make sure Bash completion is enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
rouault committed Jan 7, 2025
1 parent c2c413f commit beaa9c5
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 2 deletions.
3 changes: 3 additions & 0 deletions docker/alpine-normal/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -323,6 +323,7 @@ RUN date

RUN apk add --no-cache \
armadillo \
bash-completion \
basisu \
blosc \
brotli-libs \
Expand Down Expand Up @@ -418,3 +419,5 @@ COPY --from=builder /build/usr/share/gdal/ /usr/share/gdal/
COPY --from=builder /build/usr/include/ /usr/include/
COPY --from=builder /build_gdal_python/usr/ /usr/
COPY --from=builder /build_gdal_version_changing/usr/ /usr/

CMD ["/bin/bash", "-l"]
3 changes: 3 additions & 0 deletions docker/alpine-small/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@ RUN date

RUN apk add --no-cache \
libstdc++ \
bash-completion \
sqlite-libs \
libcurl tiff \
zlib zstd-libs lz4-libs libdeflate libarchive \
Expand All @@ -195,3 +196,5 @@ COPY --from=builder /build/usr/share/bash-completion/ /usr/share/bash-completio
COPY --from=builder /build/usr/share/gdal/ /usr/share/gdal/
COPY --from=builder /build/usr/include/ /usr/include/
COPY --from=builder /build_gdal_version_changing/usr/ /usr/

CMD ["/bin/bash", "-l"]
6 changes: 5 additions & 1 deletion docker/ubuntu-full/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -527,7 +527,7 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
wget curl unzip ca-certificates \
# GDAL dependencies
&& apt-get install -y \
libopenjp2-7 libcairo2 python3-numpy \
bash-completion libopenjp2-7 libcairo2 python3-numpy \
libpng16-16 libjpeg-turbo8 libgif7 liblzma5 libgeos3.12.1 libgeos-c1v5 \
libxml2 libexpat1 \
libxerces-c3.2 libnetcdf-c++4-1 netcdf-bin libpoppler134 libspatialite8 librasterlite2-1 gpsbabel \
Expand Down Expand Up @@ -619,3 +619,7 @@ RUN ldconfig
RUN if test "$(uname -p)" = "x86_64"; then \
ogrinfo ADBC::memory: -oo ADBC_DRIVER=duckdb -oo PRELUDE_STATEMENTS="INSTALL spatial"; \
fi

RUN echo "source /usr/share/bash-completion/bash_completion" >> /root/.bashrc

CMD ["/bin/bash", "-l"]
6 changes: 5 additions & 1 deletion docker/ubuntu-small/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
curl unzip ca-certificates \
# GDAL dependencies
&& apt-get install -y --no-install-recommends \
python3-numpy libpython3.12 \
bash-completion python3-numpy libpython3.12 \
libjpeg-turbo8 libgeos3.12.1 libgeos-c1v5 \
libexpat1 \
libxerces-c3.2 \
Expand Down Expand Up @@ -265,3 +265,7 @@ COPY --from=builder /build_gdal_python/usr/ /usr/
COPY --from=builder /build_gdal_version_changing/usr/ /usr/

RUN ldconfig

RUN echo "source /usr/share/bash-completion/bash_completion" >> /root/.bashrc

CMD ["/bin/bash", "-l"]

0 comments on commit beaa9c5

Please sign in to comment.