Skip to content

Commit 59af1d4

Browse files
committed
fixes postgresql image
1 parent 27d25c5 commit 59af1d4

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

Dockerfile.postgresql

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ FROM postgres:16.9-bookworm@sha256:fec2740c517838d4f582e48a8a9a1cb51082af3dcae59
2020
RUN apt-get update && apt-get install -y \
2121
git \
2222
build-essential \
23+
postgresql-server-dev-16 \
2324
postgresql-server-dev-all && \
2425
echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && \
2526
locale-gen en_US.UTF-8
@@ -32,10 +33,16 @@ ENV LC_ALL=en_US.UTF-8
3233
# Clone the pg-semver repository
3334
RUN git clone https://github.com/theory/pg-semver.git /pg-semver
3435

35-
# Build and install pg-semver
36+
# Build and install pg-semver with proper PostgreSQL version
3637
RUN cd /pg-semver && \
38+
export PG_CONFIG=/usr/lib/postgresql/16/bin/pg_config && \
39+
export PATH="/usr/lib/postgresql/16/bin:$PATH" && \
40+
make clean && \
3741
make && \
38-
make install
42+
make install && \
43+
# Verify the extension files are installed correctly for PostgreSQL 16
44+
echo "Checking installed semver files:" && \
45+
find /usr -name "*semver*" -type f 2>/dev/null
3946

4047
# Clean up the build dependencies to keep the image size down
4148
RUN apt-get remove -y git build-essential postgresql-server-dev-all && \

0 commit comments

Comments
 (0)