Update to the latest Alpine release

Add libldap, which is now required for libpq, and remove 9.6 support.
This commit is contained in:
Dave Page 2021-11-30 11:56:41 +00:00
parent 976faa5e2f
commit 1438eb6364
2 changed files with 6 additions and 12 deletions

View File

@ -12,7 +12,7 @@
# and clean up the web/ source code
#########################################################################
FROM alpine:3.14 AS app-builder
FROM alpine:3.15 AS app-builder
RUN apk add --no-cache \
autoconf \
@ -60,7 +60,7 @@ RUN export CPPFLAGS="-DPNG_ARM_NEON_OPT=0" && \
# Next, create the base environment for Python
#########################################################################
FROM alpine:3.14 as env-builder
FROM alpine:3.15 as env-builder
# Install dependencies
COPY requirements.txt /
@ -108,21 +108,15 @@ RUN rm -rf /pgadmin4/docs/en_US/_build/html/_static/*.png
# Create additional builders to get all of the PostgreSQL utilities
#########################################################################
FROM postgres:9.6-alpine as pg96-builder
FROM postgres:10-alpine as pg10-builder
FROM postgres:11-alpine as pg11-builder
FROM postgres:12-alpine as pg12-builder
FROM postgres:13-alpine as pg13-builder
FROM postgres:14-alpine as pg14-builder
FROM alpine:3.14 as tool-builder
FROM alpine:3.15 as tool-builder
# Copy the PG binaries
COPY --from=pg96-builder /usr/local/bin/pg_dump /usr/local/pgsql/pgsql-9.6/
COPY --from=pg96-builder /usr/local/bin/pg_dumpall /usr/local/pgsql/pgsql-9.6/
COPY --from=pg96-builder /usr/local/bin/pg_restore /usr/local/pgsql/pgsql-9.6/
COPY --from=pg96-builder /usr/local/bin/psql /usr/local/pgsql/pgsql-9.6/
COPY --from=pg10-builder /usr/local/bin/pg_dump /usr/local/pgsql/pgsql-10/
COPY --from=pg10-builder /usr/local/bin/pg_dumpall /usr/local/pgsql/pgsql-10/
COPY --from=pg10-builder /usr/local/bin/pg_restore /usr/local/pgsql/pgsql-10/
@ -152,7 +146,7 @@ COPY --from=pg14-builder /usr/local/bin/psql /usr/local/pgsql/pgsql-14/
# Assemble everything into the final container.
#########################################################################
FROM alpine:3.14
FROM alpine:3.15
# Copy in the Python packages
COPY --from=env-builder /venv /venv
@ -186,6 +180,7 @@ RUN apk add \
shadow \
sudo \
libedit \
libldap \
libcap && \
/venv/bin/python3 -m pip install --no-cache-dir gunicorn && \
find / -type d -name '__pycache__' -exec rm -rf {} + && \

View File

@ -15,8 +15,7 @@ DEFAULT_BINARY_PATHS = {
'pg-13': '/usr/local/pgsql-13',
'pg-12': '/usr/local/pgsql-12',
'pg-11': '/usr/local/pgsql-11',
'pg-10': '/usr/local/pgsql-10',
'pg-9.6': '/usr/local/pgsql-9.6'
'pg-10': '/usr/local/pgsql-10'
}
EOF