Tag

library/postgres:18beta1-alpine3.21
Content Digest: sha256:e1d53a7f2dca7f95787ac0f50c6ea2add2a7ed8bc6f38cd5c33e4dc52ee89577
Manifests
Details
Content Digest

sha256:e127926a09f5c7e8bdf24a60e4460508017af192ba791d34f8a304ec5492d976

Created

2025-06-06 18:27:47 UTC

Size

112 MB


Environment
DOCKER_PG_LLVM_DEPS

llvm19-dev clang19

GOSU_VERSION

1.17

LANG

en_US.utf8

PATH

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

PGDATA

/var/lib/postgresql/18/docker

PG_MAJOR

18

PG_SHA256

0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

PG_VERSION

18beta1


Layers

[#000] sha256:47ad0adcb4aa253584437783c542bfbd2276c07a7a0b7487bb26f9b2e80cba73 - 2.93% (3.3 MB)

[#001] sha256:972efab51fae22f4fafff32600331500f5cecfa205687f6951b1a7ee966f6fe2 - 0.0% (971 Bytes)

[#002] sha256:d8d43cf47b6d2d12e96c6d1481f9da911508b8751b5f748c4ce7fea86d2f57b4 - 0.93% (1.04 MB)

[#003] sha256:55a2688edc6211c835b091589c1e5b0cee5aca8876ffe84fa9ab10bf9ffd1378 - 0.0% (116 Bytes)

[#004] sha256:4bbb6ee4645653ed31e1cb93d42f703642b53df9b1a6dbd8eb9a85a373544118 - 96.12% (108 MB)

[#005] sha256:6e140fdb400b79143b36346b0057fac77bd724a010267dfc8327f83d77068216 - 0.02% (18.4 KB)

[#006] sha256:f563d2ed474036749823f2ef82338adf85471b2220ff266a3a6d2050592a1e08 - 0.0% (129 Bytes)

[#007] sha256:40bb854a09dfdf33fe2c3f5ff4d4f2a00afebb43ddb55362b0fd377934844992 - 0.0% (184 Bytes)

[#008] sha256:6bf427ccb1d4c5ba4234c8a1225ebb870e1189f3de71c8273f54ec33450f06ae - 0.01% (5.79 KB)

[#009] sha256:c3f74476a8f004775e2fd16db99614734139a06687cbc06d2a7fca0330596a2a - 0.0% (185 Bytes)


History
2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ADD alpine-minirootfs-3.21.4-x86.tar.gz / # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["/bin/sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; addgroup -g 70 -S postgres; adduser -u 70 -S -D -G postgres -H -h /var/lib/postgresql -s /bin/sh postgres; install --verbose --directory --owner postgres --group postgres --mode 1777 /var/lib/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV GOSU_VERSION=1.17

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; apk add --no-cache --virtual .gosu-deps ca-certificates dpkg gnupg ; dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch"; wget -O /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; export GNUPGHOME="$(mktemp -d)"; gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; gpgconf --kill all; rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; apk del --no-network .gosu-deps; chmod +x /usr/local/bin/gosu; gosu --version; gosu nobody true # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV LANG=en_US.utf8

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_MAJOR=18

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_VERSION=18beta1

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_SHA256=0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV DOCKER_PG_LLVM_DEPS=llvm19-dev clang19

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; wget -O postgresql.tar.bz2 "https://ftp.postgresql.org/pub/source/v$PG_VERSION/postgresql-$PG_VERSION.tar.bz2"; echo "$PG_SHA256 *postgresql.tar.bz2" | sha256sum -c -; mkdir -p /usr/src/postgresql; tar --extract --file postgresql.tar.bz2 --directory /usr/src/postgresql --strip-components 1 ; rm postgresql.tar.bz2; apk add --no-cache --virtual .build-deps $DOCKER_PG_LLVM_DEPS bison coreutils dpkg-dev dpkg flex g++ gcc krb5-dev libc-dev libedit-dev libxml2-dev libxslt-dev linux-headers make openldap-dev openssl-dev perl-dev perl-ipc-run perl-utils python3-dev tcl-dev util-linux-dev zlib-dev icu-dev lz4-dev zstd-dev ; cd /usr/src/postgresql; awk '$1 == "#define" && $2 == "DEFAULT_PGSOCKET_DIR" && $3 == "\"/tmp\"" { $3 = "\"/var/run/postgresql\""; print; next } { print }' src/include/pg_config_manual.h > src/include/pg_config_manual.h.new; grep '/var/run/postgresql' src/include/pg_config_manual.h.new; mv src/include/pg_config_manual.h.new src/include/pg_config_manual.h; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; export LLVM_CONFIG="/usr/lib/llvm19/bin/llvm-config"; export CLANG=clang-19; ./configure --enable-option-checking=fatal --build="$gnuArch" --enable-integer-datetimes --enable-tap-tests --disable-rpath --with-uuid=e2fs --with-pgport=5432 --with-system-tzdata=/usr/share/zoneinfo --prefix=/usr/local --with-includes=/usr/local/include --with-libraries=/usr/local/lib --with-gssapi --with-ldap --with-tcl --with-perl --with-python --with-openssl --with-libxml --with-libxslt --with-icu --with-llvm --with-lz4 --with-zstd ; make -j "$(nproc)" world-bin; make install-world-bin; make -C contrib install; runDeps="$( scanelf --needed --nobanner --format '%n#p' --recursive /usr/local | tr ',' '\n' | sort -u | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' | grep -v -e perl -e python -e tcl )"; apk add --no-cache --virtual .postgresql-rundeps $runDeps bash tzdata zstd icu-data-full $([ "$(apk --print-arch)" != 'ppc64le' ] && echo 'nss_wrapper') ; apk del --no-network .build-deps; cd /; rm -rf /usr/src/postgresql /usr/local/share/doc /usr/local/share/man ; postgres --version # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; cp -v /usr/local/share/postgresql/postgresql.conf.sample /usr/local/share/postgresql/postgresql.conf.sample.orig; sed -ri "s!^#?(listen_addresses)\s*=\s*\S+.*!\1 = '*'!" /usr/local/share/postgresql/postgresql.conf.sample; grep -F "listen_addresses = '*'" /usr/local/share/postgresql/postgresql.conf.sample # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 3777 /var/run/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PGDATA=/var/lib/postgresql/18/docker

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -svT . /var/lib/postgresql/data # https://github.com/docker-library/postgres/pull/1259#issuecomment-2215477494 # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

VOLUME [/var/lib/postgresql]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENTRYPOINT ["docker-entrypoint.sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

STOPSIGNAL SIGINT

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

EXPOSE map[5432/tcp:{}]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["postgres"]

Details
Content Digest

sha256:ab49f162bfb5098b16364aab054d78b4cf812626509cf6e00e4b4f436f36f690

Created

2025-06-06 18:27:47 UTC

Size

106 MB


Environment
DOCKER_PG_LLVM_DEPS

llvm19-dev clang19

GOSU_VERSION

1.17

LANG

en_US.utf8

PATH

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

PGDATA

/var/lib/postgresql/18/docker

PG_MAJOR

18

PG_SHA256

0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

PG_VERSION

18beta1


Layers

[#000] sha256:0368fd46e3c6d237d81390ff086f93aee216df5cfa814041a491453fb0932a12 - 3.26% (3.47 MB)

[#001] sha256:8d902c14450aa7f750a178dcd3fbb7e8ee82859e3cf56b13068966c99609ad3e - 0.0% (970 Bytes)

[#002] sha256:3ecf96b00b42a1ce10114784d86016a3de568ed2cd81edb1a8b8e6a2a4d9d59f - 1.0% (1.06 MB)

[#003] sha256:6f3b6f849a12bc598c6845a79d0fe4616fe0c93d6b6d2f921b5cf40d8af3c246 - 0.0% (116 Bytes)

[#004] sha256:4e6d28eeb5b2642153783d6bc98eeec9d8cdc963ba171f1925b0ca880001f28f - 95.72% (102 MB)

[#005] sha256:5d27d17f18aec620abdf2b6df8d5cbff0bc3b9ba7c03111e33338a04a9f80b71 - 0.02% (18.4 KB)

[#006] sha256:3c62fd76059ee2efcc83a02dcafb0c3c723701d92f8778f260d8280d07cf3498 - 0.0% (128 Bytes)

[#007] sha256:d3642ff016381a3c948da3a6490658854a9a018cade4fc31f21389f6c36ee888 - 0.0% (184 Bytes)

[#008] sha256:c0604908a2362de9d280db6068d6028c4a79a9dd01f94fd4654887226ada016e - 0.01% (5.78 KB)

[#009] sha256:c5dd91cc53634cdf4cd0704897d785572876661f48d06a46deae5471ce2bfef5 - 0.0% (182 Bytes)


History
2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ADD alpine-minirootfs-3.21.4-x86_64.tar.gz / # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["/bin/sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; addgroup -g 70 -S postgres; adduser -u 70 -S -D -G postgres -H -h /var/lib/postgresql -s /bin/sh postgres; install --verbose --directory --owner postgres --group postgres --mode 1777 /var/lib/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV GOSU_VERSION=1.17

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; apk add --no-cache --virtual .gosu-deps ca-certificates dpkg gnupg ; dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch"; wget -O /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; export GNUPGHOME="$(mktemp -d)"; gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; gpgconf --kill all; rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; apk del --no-network .gosu-deps; chmod +x /usr/local/bin/gosu; gosu --version; gosu nobody true # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV LANG=en_US.utf8

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_MAJOR=18

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_VERSION=18beta1

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_SHA256=0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV DOCKER_PG_LLVM_DEPS=llvm19-dev clang19

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; wget -O postgresql.tar.bz2 "https://ftp.postgresql.org/pub/source/v$PG_VERSION/postgresql-$PG_VERSION.tar.bz2"; echo "$PG_SHA256 *postgresql.tar.bz2" | sha256sum -c -; mkdir -p /usr/src/postgresql; tar --extract --file postgresql.tar.bz2 --directory /usr/src/postgresql --strip-components 1 ; rm postgresql.tar.bz2; apk add --no-cache --virtual .build-deps $DOCKER_PG_LLVM_DEPS bison coreutils dpkg-dev dpkg flex g++ gcc krb5-dev libc-dev libedit-dev libxml2-dev libxslt-dev linux-headers make openldap-dev openssl-dev perl-dev perl-ipc-run perl-utils python3-dev tcl-dev util-linux-dev zlib-dev icu-dev lz4-dev zstd-dev ; cd /usr/src/postgresql; awk '$1 == "#define" && $2 == "DEFAULT_PGSOCKET_DIR" && $3 == "\"/tmp\"" { $3 = "\"/var/run/postgresql\""; print; next } { print }' src/include/pg_config_manual.h > src/include/pg_config_manual.h.new; grep '/var/run/postgresql' src/include/pg_config_manual.h.new; mv src/include/pg_config_manual.h.new src/include/pg_config_manual.h; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; export LLVM_CONFIG="/usr/lib/llvm19/bin/llvm-config"; export CLANG=clang-19; ./configure --enable-option-checking=fatal --build="$gnuArch" --enable-integer-datetimes --enable-tap-tests --disable-rpath --with-uuid=e2fs --with-pgport=5432 --with-system-tzdata=/usr/share/zoneinfo --prefix=/usr/local --with-includes=/usr/local/include --with-libraries=/usr/local/lib --with-gssapi --with-ldap --with-tcl --with-perl --with-python --with-openssl --with-libxml --with-libxslt --with-icu --with-llvm --with-lz4 --with-zstd ; make -j "$(nproc)" world-bin; make install-world-bin; make -C contrib install; runDeps="$( scanelf --needed --nobanner --format '%n#p' --recursive /usr/local | tr ',' '\n' | sort -u | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' | grep -v -e perl -e python -e tcl )"; apk add --no-cache --virtual .postgresql-rundeps $runDeps bash tzdata zstd icu-data-full $([ "$(apk --print-arch)" != 'ppc64le' ] && echo 'nss_wrapper') ; apk del --no-network .build-deps; cd /; rm -rf /usr/src/postgresql /usr/local/share/doc /usr/local/share/man ; postgres --version # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; cp -v /usr/local/share/postgresql/postgresql.conf.sample /usr/local/share/postgresql/postgresql.conf.sample.orig; sed -ri "s!^#?(listen_addresses)\s*=\s*\S+.*!\1 = '*'!" /usr/local/share/postgresql/postgresql.conf.sample; grep -F "listen_addresses = '*'" /usr/local/share/postgresql/postgresql.conf.sample # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 3777 /var/run/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PGDATA=/var/lib/postgresql/18/docker

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -svT . /var/lib/postgresql/data # https://github.com/docker-library/postgres/pull/1259#issuecomment-2215477494 # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

VOLUME [/var/lib/postgresql]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENTRYPOINT ["docker-entrypoint.sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

STOPSIGNAL SIGINT

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

EXPOSE map[5432/tcp:{}]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["postgres"]

Details
Content Digest

sha256:dfded906b5d4d1cc5eeff83377966392dfbb89ae6befefd3fa5fba2643826f25

Created

2025-06-06 18:27:47 UTC

Size

87 MB


Environment
DOCKER_PG_LLVM_DEPS

llvm19-dev clang19

GOSU_VERSION

1.17

LANG

en_US.utf8

PATH

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

PGDATA

/var/lib/postgresql/18/docker

PG_MAJOR

18

PG_SHA256

0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

PG_VERSION

18beta1


Layers

[#000] sha256:ca0c331561564c536ffa9246944bb50ac21d3fb11fe66c38baad97fdd1f05719 - 3.69% (3.21 MB)

[#001] sha256:98c24d3e045a6ae3a2737e134a0660bb67966f1c4c59f473117ca5bfb7f462df - 0.0% (969 Bytes)

[#002] sha256:b85a4c1614afc683eca7c5ab777456f2ae53dd7e1347e7e75764a6a74abf3b8b - 1.19% (1.03 MB)

[#003] sha256:1e5769312ee59aeeaaf29de04675a714c2accdd298581e883e9228f0d01acbd5 - 0.0% (116 Bytes)

[#004] sha256:df8f9e25c9b5f4cb848e0ade44068fd6682c4420dd3d0b15a0a65dc6f6157ef0 - 95.1% (82.8 MB)

[#005] sha256:458e4da3203cd11edfb29fc0ad1fd0f932da48fbbca07e5966858fd7022f0a0f - 0.02% (18.4 KB)

[#006] sha256:4c47804d6a2a48b80b451ace2190a0e3f56e71d562d985e235da1dd320bd32b4 - 0.0% (128 Bytes)

[#007] sha256:0f1fbb1e6b7bd908c0509d58c0414f616a9c51115cf20788695ac9d05167c94c - 0.0% (183 Bytes)

[#008] sha256:48736e71f0df4eaab9b5deff8bc9d7bd6a16b8479a5c0a27a133ac859a9a8479 - 0.01% (5.79 KB)

[#009] sha256:e2d2786304d3d0598f189a0060343dbd66e80fd9994ec52874c4eff1e31ddc9a - 0.0% (186 Bytes)


History
2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ADD alpine-minirootfs-3.21.4-armhf.tar.gz / # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["/bin/sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; addgroup -g 70 -S postgres; adduser -u 70 -S -D -G postgres -H -h /var/lib/postgresql -s /bin/sh postgres; install --verbose --directory --owner postgres --group postgres --mode 1777 /var/lib/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV GOSU_VERSION=1.17

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; apk add --no-cache --virtual .gosu-deps ca-certificates dpkg gnupg ; dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch"; wget -O /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; export GNUPGHOME="$(mktemp -d)"; gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; gpgconf --kill all; rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; apk del --no-network .gosu-deps; chmod +x /usr/local/bin/gosu; gosu --version; gosu nobody true # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV LANG=en_US.utf8

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_MAJOR=18

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_VERSION=18beta1

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_SHA256=0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV DOCKER_PG_LLVM_DEPS=llvm19-dev clang19

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; wget -O postgresql.tar.bz2 "https://ftp.postgresql.org/pub/source/v$PG_VERSION/postgresql-$PG_VERSION.tar.bz2"; echo "$PG_SHA256 *postgresql.tar.bz2" | sha256sum -c -; mkdir -p /usr/src/postgresql; tar --extract --file postgresql.tar.bz2 --directory /usr/src/postgresql --strip-components 1 ; rm postgresql.tar.bz2; apk add --no-cache --virtual .build-deps $DOCKER_PG_LLVM_DEPS bison coreutils dpkg-dev dpkg flex g++ gcc krb5-dev libc-dev libedit-dev libxml2-dev libxslt-dev linux-headers make openldap-dev openssl-dev perl-dev perl-ipc-run perl-utils python3-dev tcl-dev util-linux-dev zlib-dev icu-dev lz4-dev zstd-dev ; cd /usr/src/postgresql; awk '$1 == "#define" && $2 == "DEFAULT_PGSOCKET_DIR" && $3 == "\"/tmp\"" { $3 = "\"/var/run/postgresql\""; print; next } { print }' src/include/pg_config_manual.h > src/include/pg_config_manual.h.new; grep '/var/run/postgresql' src/include/pg_config_manual.h.new; mv src/include/pg_config_manual.h.new src/include/pg_config_manual.h; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; export LLVM_CONFIG="/usr/lib/llvm19/bin/llvm-config"; export CLANG=clang-19; ./configure --enable-option-checking=fatal --build="$gnuArch" --enable-integer-datetimes --enable-tap-tests --disable-rpath --with-uuid=e2fs --with-pgport=5432 --with-system-tzdata=/usr/share/zoneinfo --prefix=/usr/local --with-includes=/usr/local/include --with-libraries=/usr/local/lib --with-gssapi --with-ldap --with-tcl --with-perl --with-python --with-openssl --with-libxml --with-libxslt --with-icu --with-llvm --with-lz4 --with-zstd ; make -j "$(nproc)" world-bin; make install-world-bin; make -C contrib install; runDeps="$( scanelf --needed --nobanner --format '%n#p' --recursive /usr/local | tr ',' '\n' | sort -u | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' | grep -v -e perl -e python -e tcl )"; apk add --no-cache --virtual .postgresql-rundeps $runDeps bash tzdata zstd icu-data-full $([ "$(apk --print-arch)" != 'ppc64le' ] && echo 'nss_wrapper') ; apk del --no-network .build-deps; cd /; rm -rf /usr/src/postgresql /usr/local/share/doc /usr/local/share/man ; postgres --version # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; cp -v /usr/local/share/postgresql/postgresql.conf.sample /usr/local/share/postgresql/postgresql.conf.sample.orig; sed -ri "s!^#?(listen_addresses)\s*=\s*\S+.*!\1 = '*'!" /usr/local/share/postgresql/postgresql.conf.sample; grep -F "listen_addresses = '*'" /usr/local/share/postgresql/postgresql.conf.sample # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 3777 /var/run/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PGDATA=/var/lib/postgresql/18/docker

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -svT . /var/lib/postgresql/data # https://github.com/docker-library/postgres/pull/1259#issuecomment-2215477494 # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

VOLUME [/var/lib/postgresql]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENTRYPOINT ["docker-entrypoint.sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

STOPSIGNAL SIGINT

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

EXPOSE map[5432/tcp:{}]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["postgres"]

Details
Content Digest

sha256:0619920b655493f0911c131771cb6a9ffefbfc690bf123c8607317e35328a5ef

Created

2025-06-06 18:27:47 UTC

Size

82.4 MB


Environment
DOCKER_PG_LLVM_DEPS

llvm19-dev clang19

GOSU_VERSION

1.17

LANG

en_US.utf8

PATH

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

PGDATA

/var/lib/postgresql/18/docker

PG_MAJOR

18

PG_SHA256

0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

PG_VERSION

18beta1


Layers

[#000] sha256:a96f521d793eec1dcb2b825985eb01c309edb500ebd753a2f84cb9430f05802f - 3.58% (2.95 MB)

[#001] sha256:72f3486cf29d0276b4ac8fbb65b102ab22ae5618fb042837b80f87e637b02102 - 0.0% (966 Bytes)

[#002] sha256:e280f6d7d0584205565e6b71ba0d85887f9a443bdeb5686d452b8c7e204d5be4 - 1.25% (1.03 MB)

[#003] sha256:5842d1d4a5f1e2a15d29c0966c9de4b139ad565b29eb3c1296c5f5b66c2fcbf3 - 0.0% (116 Bytes)

[#004] sha256:04416c83cabadeb379f060e68c51197c169acdfca833979a772b8cb0e030c576 - 95.13% (78.4 MB)

[#005] sha256:322ed510d01943d7699a20a8b531a083daa636dc87ea8be5f902e240028d0400 - 0.02% (18.4 KB)

[#006] sha256:76369f56c8feb1a585f305d13c3334210e7d32f8b5455149433447c5ca2ad430 - 0.0% (128 Bytes)

[#007] sha256:2b1de298e8a434a12bc55053712439b3dabe48babab22614bae7b4f7daa50a24 - 0.0% (184 Bytes)

[#008] sha256:594abf2d2fc6e0d1149577261fed0f8a3d2201fbbaafbdaa6cf1264dde987998 - 0.01% (5.79 KB)

[#009] sha256:8c5e415faf4437165a181a222403c4ec780eb2d59499c849e8e59bc77e522855 - 0.0% (186 Bytes)


History
2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ADD alpine-minirootfs-3.21.4-armv7.tar.gz / # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["/bin/sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; addgroup -g 70 -S postgres; adduser -u 70 -S -D -G postgres -H -h /var/lib/postgresql -s /bin/sh postgres; install --verbose --directory --owner postgres --group postgres --mode 1777 /var/lib/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV GOSU_VERSION=1.17

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; apk add --no-cache --virtual .gosu-deps ca-certificates dpkg gnupg ; dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch"; wget -O /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; export GNUPGHOME="$(mktemp -d)"; gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; gpgconf --kill all; rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; apk del --no-network .gosu-deps; chmod +x /usr/local/bin/gosu; gosu --version; gosu nobody true # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV LANG=en_US.utf8

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_MAJOR=18

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_VERSION=18beta1

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_SHA256=0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV DOCKER_PG_LLVM_DEPS=llvm19-dev clang19

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; wget -O postgresql.tar.bz2 "https://ftp.postgresql.org/pub/source/v$PG_VERSION/postgresql-$PG_VERSION.tar.bz2"; echo "$PG_SHA256 *postgresql.tar.bz2" | sha256sum -c -; mkdir -p /usr/src/postgresql; tar --extract --file postgresql.tar.bz2 --directory /usr/src/postgresql --strip-components 1 ; rm postgresql.tar.bz2; apk add --no-cache --virtual .build-deps $DOCKER_PG_LLVM_DEPS bison coreutils dpkg-dev dpkg flex g++ gcc krb5-dev libc-dev libedit-dev libxml2-dev libxslt-dev linux-headers make openldap-dev openssl-dev perl-dev perl-ipc-run perl-utils python3-dev tcl-dev util-linux-dev zlib-dev icu-dev lz4-dev zstd-dev ; cd /usr/src/postgresql; awk '$1 == "#define" && $2 == "DEFAULT_PGSOCKET_DIR" && $3 == "\"/tmp\"" { $3 = "\"/var/run/postgresql\""; print; next } { print }' src/include/pg_config_manual.h > src/include/pg_config_manual.h.new; grep '/var/run/postgresql' src/include/pg_config_manual.h.new; mv src/include/pg_config_manual.h.new src/include/pg_config_manual.h; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; export LLVM_CONFIG="/usr/lib/llvm19/bin/llvm-config"; export CLANG=clang-19; ./configure --enable-option-checking=fatal --build="$gnuArch" --enable-integer-datetimes --enable-tap-tests --disable-rpath --with-uuid=e2fs --with-pgport=5432 --with-system-tzdata=/usr/share/zoneinfo --prefix=/usr/local --with-includes=/usr/local/include --with-libraries=/usr/local/lib --with-gssapi --with-ldap --with-tcl --with-perl --with-python --with-openssl --with-libxml --with-libxslt --with-icu --with-llvm --with-lz4 --with-zstd ; make -j "$(nproc)" world-bin; make install-world-bin; make -C contrib install; runDeps="$( scanelf --needed --nobanner --format '%n#p' --recursive /usr/local | tr ',' '\n' | sort -u | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' | grep -v -e perl -e python -e tcl )"; apk add --no-cache --virtual .postgresql-rundeps $runDeps bash tzdata zstd icu-data-full $([ "$(apk --print-arch)" != 'ppc64le' ] && echo 'nss_wrapper') ; apk del --no-network .build-deps; cd /; rm -rf /usr/src/postgresql /usr/local/share/doc /usr/local/share/man ; postgres --version # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; cp -v /usr/local/share/postgresql/postgresql.conf.sample /usr/local/share/postgresql/postgresql.conf.sample.orig; sed -ri "s!^#?(listen_addresses)\s*=\s*\S+.*!\1 = '*'!" /usr/local/share/postgresql/postgresql.conf.sample; grep -F "listen_addresses = '*'" /usr/local/share/postgresql/postgresql.conf.sample # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 3777 /var/run/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PGDATA=/var/lib/postgresql/18/docker

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -svT . /var/lib/postgresql/data # https://github.com/docker-library/postgres/pull/1259#issuecomment-2215477494 # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

VOLUME [/var/lib/postgresql]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENTRYPOINT ["docker-entrypoint.sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

STOPSIGNAL SIGINT

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

EXPOSE map[5432/tcp:{}]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["postgres"]

Details
Content Digest

sha256:324c304be5ee3276bdd00b51dbc89e971048e6508914cfea0cfc4feb4d57c814

Created

2025-06-06 18:27:47 UTC

Size

103 MB


Environment
DOCKER_PG_LLVM_DEPS

llvm19-dev clang19

GOSU_VERSION

1.17

LANG

en_US.utf8

PATH

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

PGDATA

/var/lib/postgresql/18/docker

PG_MAJOR

18

PG_SHA256

0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

PG_VERSION

18beta1


Layers

[#000] sha256:d06c6b665c9b4c183a2e300b290a6b4b7db03f803122fe93d91e9178f425e488 - 3.71% (3.8 MB)

[#001] sha256:8e83a04663f13f5baa82135ff9e60f9db62556460d35926ae5e559dcd004be87 - 0.0% (970 Bytes)

[#002] sha256:9a219a9326a248ea39ab113c79425302bb8b917a59f93520480153f052e8298d - 0.97% (1020 KB)

[#003] sha256:5152ed3b7b8c7c65e1a88aa24f20942679166e2c7fe88f29988782c82f546b51 - 0.0% (116 Bytes)

[#004] sha256:eb7eccb02137eb25757040f11b021e9b0d6851aa87922cab45332b7371d1bce2 - 95.3% (97.7 MB)

[#005] sha256:610cb35c86f7fff6b1cfe1540bb7b2d1ef2fd962aec9fb821e64f45d03eb1c47 - 0.02% (18.4 KB)

[#006] sha256:8c104d73943ffef5ea7cd11a6768d68796d417c5fd58e483cc49315578c49ed6 - 0.0% (128 Bytes)

[#007] sha256:d8a1f05fdcbff0721b784a3a378b00cf809e0364d2c71fbe32243680b79602f3 - 0.0% (182 Bytes)

[#008] sha256:2d9e37467405b3115648243f4507b844fd53eacf517c395a40752ce77c9e87a4 - 0.01% (5.79 KB)

[#009] sha256:6ae17ff0e8e4fa216c5585a124041924f982743478947bf2b70cfc3099270466 - 0.0% (184 Bytes)


History
2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ADD alpine-minirootfs-3.21.4-aarch64.tar.gz / # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["/bin/sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; addgroup -g 70 -S postgres; adduser -u 70 -S -D -G postgres -H -h /var/lib/postgresql -s /bin/sh postgres; install --verbose --directory --owner postgres --group postgres --mode 1777 /var/lib/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV GOSU_VERSION=1.17

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; apk add --no-cache --virtual .gosu-deps ca-certificates dpkg gnupg ; dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch"; wget -O /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; export GNUPGHOME="$(mktemp -d)"; gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; gpgconf --kill all; rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; apk del --no-network .gosu-deps; chmod +x /usr/local/bin/gosu; gosu --version; gosu nobody true # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV LANG=en_US.utf8

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_MAJOR=18

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_VERSION=18beta1

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_SHA256=0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV DOCKER_PG_LLVM_DEPS=llvm19-dev clang19

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; wget -O postgresql.tar.bz2 "https://ftp.postgresql.org/pub/source/v$PG_VERSION/postgresql-$PG_VERSION.tar.bz2"; echo "$PG_SHA256 *postgresql.tar.bz2" | sha256sum -c -; mkdir -p /usr/src/postgresql; tar --extract --file postgresql.tar.bz2 --directory /usr/src/postgresql --strip-components 1 ; rm postgresql.tar.bz2; apk add --no-cache --virtual .build-deps $DOCKER_PG_LLVM_DEPS bison coreutils dpkg-dev dpkg flex g++ gcc krb5-dev libc-dev libedit-dev libxml2-dev libxslt-dev linux-headers make openldap-dev openssl-dev perl-dev perl-ipc-run perl-utils python3-dev tcl-dev util-linux-dev zlib-dev icu-dev lz4-dev zstd-dev ; cd /usr/src/postgresql; awk '$1 == "#define" && $2 == "DEFAULT_PGSOCKET_DIR" && $3 == "\"/tmp\"" { $3 = "\"/var/run/postgresql\""; print; next } { print }' src/include/pg_config_manual.h > src/include/pg_config_manual.h.new; grep '/var/run/postgresql' src/include/pg_config_manual.h.new; mv src/include/pg_config_manual.h.new src/include/pg_config_manual.h; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; export LLVM_CONFIG="/usr/lib/llvm19/bin/llvm-config"; export CLANG=clang-19; ./configure --enable-option-checking=fatal --build="$gnuArch" --enable-integer-datetimes --enable-tap-tests --disable-rpath --with-uuid=e2fs --with-pgport=5432 --with-system-tzdata=/usr/share/zoneinfo --prefix=/usr/local --with-includes=/usr/local/include --with-libraries=/usr/local/lib --with-gssapi --with-ldap --with-tcl --with-perl --with-python --with-openssl --with-libxml --with-libxslt --with-icu --with-llvm --with-lz4 --with-zstd ; make -j "$(nproc)" world-bin; make install-world-bin; make -C contrib install; runDeps="$( scanelf --needed --nobanner --format '%n#p' --recursive /usr/local | tr ',' '\n' | sort -u | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' | grep -v -e perl -e python -e tcl )"; apk add --no-cache --virtual .postgresql-rundeps $runDeps bash tzdata zstd icu-data-full $([ "$(apk --print-arch)" != 'ppc64le' ] && echo 'nss_wrapper') ; apk del --no-network .build-deps; cd /; rm -rf /usr/src/postgresql /usr/local/share/doc /usr/local/share/man ; postgres --version # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; cp -v /usr/local/share/postgresql/postgresql.conf.sample /usr/local/share/postgresql/postgresql.conf.sample.orig; sed -ri "s!^#?(listen_addresses)\s*=\s*\S+.*!\1 = '*'!" /usr/local/share/postgresql/postgresql.conf.sample; grep -F "listen_addresses = '*'" /usr/local/share/postgresql/postgresql.conf.sample # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 3777 /var/run/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PGDATA=/var/lib/postgresql/18/docker

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -svT . /var/lib/postgresql/data # https://github.com/docker-library/postgres/pull/1259#issuecomment-2215477494 # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

VOLUME [/var/lib/postgresql]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENTRYPOINT ["docker-entrypoint.sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

STOPSIGNAL SIGINT

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

EXPOSE map[5432/tcp:{}]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["postgres"]

Details
Content Digest

sha256:da38af424a225239599c7546aa5327f4a01f0340489b288cafaf672a6dd084be

Created

2025-06-06 18:27:47 UTC

Size

91.1 MB


Environment
DOCKER_PG_LLVM_DEPS

llvm19-dev clang19

GOSU_VERSION

1.17

LANG

en_US.utf8

PATH

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

PGDATA

/var/lib/postgresql/18/docker

PG_MAJOR

18

PG_SHA256

0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

PG_VERSION

18beta1


Layers

[#000] sha256:bf93837577694839723892fa29fd11013552ac59944071e2341ac6d6d9876d29 - 3.74% (3.4 MB)

[#001] sha256:d150f0e5a84464f51b24b96104e9c461f6aa57b0d596b53a3b61d1828eb167ed - 0.0% (972 Bytes)

[#002] sha256:559507c038b9e2c6c1217225ede50c505cf2e95ec527aef9412ee27ad0a229df - 1.08% (1010 KB)

[#003] sha256:278df973f26c3299fe5435792bb8b691fda5f9d73691c5892d4c89115c051b2b - 0.0% (116 Bytes)

[#004] sha256:7b87a25bd9e5d0d249f736b681550d4134c1f0a6d4ab0c347038736db6e626b2 - 95.16% (86.7 MB)

[#005] sha256:dd2b0c40347f6f4a853ae62983eeb10fe3553aecc76648421e18b25cd000f465 - 0.02% (18.4 KB)

[#006] sha256:c4470a005585340fea464b94b98eaf27b18fd6869e1cd3657b9e0bfe2af4351d - 0.0% (128 Bytes)

[#007] sha256:b203d4e50ae7a14ab2076b321dc3779002c58284533f39891ca633646e2e467a - 0.0% (183 Bytes)

[#008] sha256:bff0ba8a342a0a4349cae350d1153db55c295db24612e91cd1f0f8257763ee8a - 0.01% (5.79 KB)

[#009] sha256:6ff7a06a09a188aae022ec32c1d69083749bda0146dd8d6992c75e7159369e9c - 0.0% (185 Bytes)


History
2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ADD alpine-minirootfs-3.21.4-ppc64le.tar.gz / # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["/bin/sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; addgroup -g 70 -S postgres; adduser -u 70 -S -D -G postgres -H -h /var/lib/postgresql -s /bin/sh postgres; install --verbose --directory --owner postgres --group postgres --mode 1777 /var/lib/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV GOSU_VERSION=1.17

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; apk add --no-cache --virtual .gosu-deps ca-certificates dpkg gnupg ; dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch"; wget -O /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; export GNUPGHOME="$(mktemp -d)"; gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; gpgconf --kill all; rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; apk del --no-network .gosu-deps; chmod +x /usr/local/bin/gosu; gosu --version; gosu nobody true # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV LANG=en_US.utf8

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_MAJOR=18

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_VERSION=18beta1

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_SHA256=0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV DOCKER_PG_LLVM_DEPS=llvm19-dev clang19

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; wget -O postgresql.tar.bz2 "https://ftp.postgresql.org/pub/source/v$PG_VERSION/postgresql-$PG_VERSION.tar.bz2"; echo "$PG_SHA256 *postgresql.tar.bz2" | sha256sum -c -; mkdir -p /usr/src/postgresql; tar --extract --file postgresql.tar.bz2 --directory /usr/src/postgresql --strip-components 1 ; rm postgresql.tar.bz2; apk add --no-cache --virtual .build-deps $DOCKER_PG_LLVM_DEPS bison coreutils dpkg-dev dpkg flex g++ gcc krb5-dev libc-dev libedit-dev libxml2-dev libxslt-dev linux-headers make openldap-dev openssl-dev perl-dev perl-ipc-run perl-utils python3-dev tcl-dev util-linux-dev zlib-dev icu-dev lz4-dev zstd-dev ; cd /usr/src/postgresql; awk '$1 == "#define" && $2 == "DEFAULT_PGSOCKET_DIR" && $3 == "\"/tmp\"" { $3 = "\"/var/run/postgresql\""; print; next } { print }' src/include/pg_config_manual.h > src/include/pg_config_manual.h.new; grep '/var/run/postgresql' src/include/pg_config_manual.h.new; mv src/include/pg_config_manual.h.new src/include/pg_config_manual.h; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; export LLVM_CONFIG="/usr/lib/llvm19/bin/llvm-config"; export CLANG=clang-19; ./configure --enable-option-checking=fatal --build="$gnuArch" --enable-integer-datetimes --enable-tap-tests --disable-rpath --with-uuid=e2fs --with-pgport=5432 --with-system-tzdata=/usr/share/zoneinfo --prefix=/usr/local --with-includes=/usr/local/include --with-libraries=/usr/local/lib --with-gssapi --with-ldap --with-tcl --with-perl --with-python --with-openssl --with-libxml --with-libxslt --with-icu --with-llvm --with-lz4 --with-zstd ; make -j "$(nproc)" world-bin; make install-world-bin; make -C contrib install; runDeps="$( scanelf --needed --nobanner --format '%n#p' --recursive /usr/local | tr ',' '\n' | sort -u | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' | grep -v -e perl -e python -e tcl )"; apk add --no-cache --virtual .postgresql-rundeps $runDeps bash tzdata zstd icu-data-full $([ "$(apk --print-arch)" != 'ppc64le' ] && echo 'nss_wrapper') ; apk del --no-network .build-deps; cd /; rm -rf /usr/src/postgresql /usr/local/share/doc /usr/local/share/man ; postgres --version # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; cp -v /usr/local/share/postgresql/postgresql.conf.sample /usr/local/share/postgresql/postgresql.conf.sample.orig; sed -ri "s!^#?(listen_addresses)\s*=\s*\S+.*!\1 = '*'!" /usr/local/share/postgresql/postgresql.conf.sample; grep -F "listen_addresses = '*'" /usr/local/share/postgresql/postgresql.conf.sample # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 3777 /var/run/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PGDATA=/var/lib/postgresql/18/docker

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -svT . /var/lib/postgresql/data # https://github.com/docker-library/postgres/pull/1259#issuecomment-2215477494 # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

VOLUME [/var/lib/postgresql]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENTRYPOINT ["docker-entrypoint.sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

STOPSIGNAL SIGINT

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

EXPOSE map[5432/tcp:{}]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["postgres"]

Details
Content Digest

sha256:b4821362d1349b2522903bcfac2cb0a2dc46f33b22aa7692de49cca1b42cc8e9

Created

2025-06-06 18:27:47 UTC

Size

107 MB


Environment
DOCKER_PG_LLVM_DEPS

llvm19-dev clang19

GOSU_VERSION

1.17

LANG

en_US.utf8

PATH

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

PGDATA

/var/lib/postgresql/18/docker

PG_MAJOR

18

PG_SHA256

0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

PG_VERSION

18beta1


Layers

[#000] sha256:3275b496853d19cc6428a9543a3884d79627e13cc07be788b5bd163f6892e987 - 2.99% (3.19 MB)

[#001] sha256:109d3c0f56503ab40c4140d482406fc770090c1cfa210c2d815c27c3258a8846 - 0.0% (972 Bytes)

[#002] sha256:9ff15b55dbea7fde51e6fef1d6c983e6787f061f6e664e60be0bed1e73ab2ba1 - 0.97% (1.04 MB)

[#003] sha256:79d3c738d93a67acc9b823f9b99c37350d12f5f2ca9149f6cfe4afa6c01a0833 - 0.0% (116 Bytes)

[#004] sha256:ce4672fa879a9a27d9131dd8becd024e0d1b6643675d5cf4b107bcbf46573d86 - 96.01% (102 MB)

[#005] sha256:98ae5372ce16d32c613b03b660a209ba8f95847cae099eaf5b238c26e190efc2 - 0.02% (18.4 KB)

[#006] sha256:940c90c28f3d3b8eb22116b994da34f65d94ceb2a91c5082bc2be3d6e1dcb879 - 0.0% (128 Bytes)

[#007] sha256:2e2e02e412c693d6e890192b5ff4582e9891645c75b40094422dfa95f9ca53ac - 0.0% (184 Bytes)

[#008] sha256:610fe3f7aef312d4b5ecdc0bdaab57a46f7ff311839a9aafe20156bf2984ab50 - 0.01% (5.79 KB)

[#009] sha256:291ea2df6af79b51f7b2cc452b03171b5ee4bc0b43f868d58ed297ea6ef19d7e - 0.0% (188 Bytes)


History
2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ADD alpine-minirootfs-3.21.4-riscv64.tar.gz / # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["/bin/sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; addgroup -g 70 -S postgres; adduser -u 70 -S -D -G postgres -H -h /var/lib/postgresql -s /bin/sh postgres; install --verbose --directory --owner postgres --group postgres --mode 1777 /var/lib/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV GOSU_VERSION=1.17

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; apk add --no-cache --virtual .gosu-deps ca-certificates dpkg gnupg ; dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch"; wget -O /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; export GNUPGHOME="$(mktemp -d)"; gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; gpgconf --kill all; rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; apk del --no-network .gosu-deps; chmod +x /usr/local/bin/gosu; gosu --version; gosu nobody true # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV LANG=en_US.utf8

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_MAJOR=18

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_VERSION=18beta1

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_SHA256=0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV DOCKER_PG_LLVM_DEPS=llvm19-dev clang19

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; wget -O postgresql.tar.bz2 "https://ftp.postgresql.org/pub/source/v$PG_VERSION/postgresql-$PG_VERSION.tar.bz2"; echo "$PG_SHA256 *postgresql.tar.bz2" | sha256sum -c -; mkdir -p /usr/src/postgresql; tar --extract --file postgresql.tar.bz2 --directory /usr/src/postgresql --strip-components 1 ; rm postgresql.tar.bz2; apk add --no-cache --virtual .build-deps $DOCKER_PG_LLVM_DEPS bison coreutils dpkg-dev dpkg flex g++ gcc krb5-dev libc-dev libedit-dev libxml2-dev libxslt-dev linux-headers make openldap-dev openssl-dev perl-dev perl-ipc-run perl-utils python3-dev tcl-dev util-linux-dev zlib-dev icu-dev lz4-dev zstd-dev ; cd /usr/src/postgresql; awk '$1 == "#define" && $2 == "DEFAULT_PGSOCKET_DIR" && $3 == "\"/tmp\"" { $3 = "\"/var/run/postgresql\""; print; next } { print }' src/include/pg_config_manual.h > src/include/pg_config_manual.h.new; grep '/var/run/postgresql' src/include/pg_config_manual.h.new; mv src/include/pg_config_manual.h.new src/include/pg_config_manual.h; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; export LLVM_CONFIG="/usr/lib/llvm19/bin/llvm-config"; export CLANG=clang-19; ./configure --enable-option-checking=fatal --build="$gnuArch" --enable-integer-datetimes --enable-tap-tests --disable-rpath --with-uuid=e2fs --with-pgport=5432 --with-system-tzdata=/usr/share/zoneinfo --prefix=/usr/local --with-includes=/usr/local/include --with-libraries=/usr/local/lib --with-gssapi --with-ldap --with-tcl --with-perl --with-python --with-openssl --with-libxml --with-libxslt --with-icu --with-llvm --with-lz4 --with-zstd ; make -j "$(nproc)" world-bin; make install-world-bin; make -C contrib install; runDeps="$( scanelf --needed --nobanner --format '%n#p' --recursive /usr/local | tr ',' '\n' | sort -u | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' | grep -v -e perl -e python -e tcl )"; apk add --no-cache --virtual .postgresql-rundeps $runDeps bash tzdata zstd icu-data-full $([ "$(apk --print-arch)" != 'ppc64le' ] && echo 'nss_wrapper') ; apk del --no-network .build-deps; cd /; rm -rf /usr/src/postgresql /usr/local/share/doc /usr/local/share/man ; postgres --version # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; cp -v /usr/local/share/postgresql/postgresql.conf.sample /usr/local/share/postgresql/postgresql.conf.sample.orig; sed -ri "s!^#?(listen_addresses)\s*=\s*\S+.*!\1 = '*'!" /usr/local/share/postgresql/postgresql.conf.sample; grep -F "listen_addresses = '*'" /usr/local/share/postgresql/postgresql.conf.sample # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 3777 /var/run/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PGDATA=/var/lib/postgresql/18/docker

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -svT . /var/lib/postgresql/data # https://github.com/docker-library/postgres/pull/1259#issuecomment-2215477494 # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

VOLUME [/var/lib/postgresql]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENTRYPOINT ["docker-entrypoint.sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

STOPSIGNAL SIGINT

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

EXPOSE map[5432/tcp:{}]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["postgres"]

Details
Content Digest

sha256:30fa061b8b9840433f1cb4e6f21322877f277e47203a2b8d140725321372d903

Created

2025-06-06 18:27:47 UTC

Size

115 MB


Environment
DOCKER_PG_LLVM_DEPS

llvm19-dev clang19

GOSU_VERSION

1.17

LANG

en_US.utf8

PATH

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

PGDATA

/var/lib/postgresql/18/docker

PG_MAJOR

18

PG_SHA256

0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

PG_VERSION

18beta1


Layers

[#000] sha256:40ef870b733fb35d27e79770e3e1133cc7c54e14d8c251e61ecccdec69c20e32 - 2.88% (3.3 MB)

[#001] sha256:f08ce6f43a6a5f10e7f4be1ad3b21d953126a6a3fadf3e2748946ca632e9cccb - 0.0% (969 Bytes)

[#002] sha256:405b45240bca888a7a97d0169873d3fe563c9899d16570f76b85d85bb758d59f - 0.9% (1.03 MB)

[#003] sha256:2461363266a22cbd95730c416df140d01b4559da8b795a393e3e11c32b052cf9 - 0.0% (116 Bytes)

[#004] sha256:47744f528bb743fdac55b6ea748540730b062264028223724d96ac96049f336a - 96.2% (110 MB)

[#005] sha256:17d60aa43e329cde9e377c40179840a525d48974d0371942570273e7722c57ff - 0.02% (18.4 KB)

[#006] sha256:0df669bf43fd921e04ad3412fd24e1866db083d7aebd85cd83f2d7e0ae02c5e6 - 0.0% (129 Bytes)

[#007] sha256:d2d57c40c553574f4964e360d7752ad8171583a15cebc5aae341bb0dbea8e441 - 0.0% (184 Bytes)

[#008] sha256:70c16c2cca0fe1f50abba7b7ff8d544eddbda65fbb8f37ebc5e1e8088a8ec6f9 - 0.0% (5.79 KB)

[#009] sha256:28beb5f926291332ef72ac6308b6e7213514e96b0df30430d5af7f9832fff525 - 0.0% (185 Bytes)


History
2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ADD alpine-minirootfs-3.21.4-s390x.tar.gz / # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["/bin/sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; addgroup -g 70 -S postgres; adduser -u 70 -S -D -G postgres -H -h /var/lib/postgresql -s /bin/sh postgres; install --verbose --directory --owner postgres --group postgres --mode 1777 /var/lib/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV GOSU_VERSION=1.17

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; apk add --no-cache --virtual .gosu-deps ca-certificates dpkg gnupg ; dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch"; wget -O /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; export GNUPGHOME="$(mktemp -d)"; gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; gpgconf --kill all; rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; apk del --no-network .gosu-deps; chmod +x /usr/local/bin/gosu; gosu --version; gosu nobody true # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV LANG=en_US.utf8

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_MAJOR=18

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_VERSION=18beta1

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PG_SHA256=0b7c83df6195398aa67dbf5c002e7fa4082be393aae99aa69926d483f98eb885

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV DOCKER_PG_LLVM_DEPS=llvm19-dev clang19

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; wget -O postgresql.tar.bz2 "https://ftp.postgresql.org/pub/source/v$PG_VERSION/postgresql-$PG_VERSION.tar.bz2"; echo "$PG_SHA256 *postgresql.tar.bz2" | sha256sum -c -; mkdir -p /usr/src/postgresql; tar --extract --file postgresql.tar.bz2 --directory /usr/src/postgresql --strip-components 1 ; rm postgresql.tar.bz2; apk add --no-cache --virtual .build-deps $DOCKER_PG_LLVM_DEPS bison coreutils dpkg-dev dpkg flex g++ gcc krb5-dev libc-dev libedit-dev libxml2-dev libxslt-dev linux-headers make openldap-dev openssl-dev perl-dev perl-ipc-run perl-utils python3-dev tcl-dev util-linux-dev zlib-dev icu-dev lz4-dev zstd-dev ; cd /usr/src/postgresql; awk '$1 == "#define" && $2 == "DEFAULT_PGSOCKET_DIR" && $3 == "\"/tmp\"" { $3 = "\"/var/run/postgresql\""; print; next } { print }' src/include/pg_config_manual.h > src/include/pg_config_manual.h.new; grep '/var/run/postgresql' src/include/pg_config_manual.h.new; mv src/include/pg_config_manual.h.new src/include/pg_config_manual.h; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; export LLVM_CONFIG="/usr/lib/llvm19/bin/llvm-config"; export CLANG=clang-19; ./configure --enable-option-checking=fatal --build="$gnuArch" --enable-integer-datetimes --enable-tap-tests --disable-rpath --with-uuid=e2fs --with-pgport=5432 --with-system-tzdata=/usr/share/zoneinfo --prefix=/usr/local --with-includes=/usr/local/include --with-libraries=/usr/local/lib --with-gssapi --with-ldap --with-tcl --with-perl --with-python --with-openssl --with-libxml --with-libxslt --with-icu --with-llvm --with-lz4 --with-zstd ; make -j "$(nproc)" world-bin; make install-world-bin; make -C contrib install; runDeps="$( scanelf --needed --nobanner --format '%n#p' --recursive /usr/local | tr ',' '\n' | sort -u | awk 'system("[ -e /usr/local/lib/" $1 " ]") == 0 { next } { print "so:" $1 }' | grep -v -e perl -e python -e tcl )"; apk add --no-cache --virtual .postgresql-rundeps $runDeps bash tzdata zstd icu-data-full $([ "$(apk --print-arch)" != 'ppc64le' ] && echo 'nss_wrapper') ; apk del --no-network .build-deps; cd /; rm -rf /usr/src/postgresql /usr/local/share/doc /usr/local/share/man ; postgres --version # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c set -eux; cp -v /usr/local/share/postgresql/postgresql.conf.sample /usr/local/share/postgresql/postgresql.conf.sample.orig; sed -ri "s!^#?(listen_addresses)\s*=\s*\S+.*!\1 = '*'!" /usr/local/share/postgresql/postgresql.conf.sample; grep -F "listen_addresses = '*'" /usr/local/share/postgresql/postgresql.conf.sample # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 3777 /var/run/postgresql # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENV PGDATA=/var/lib/postgresql/18/docker

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -svT . /var/lib/postgresql/data # https://github.com/docker-library/postgres/pull/1259#issuecomment-2215477494 # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

VOLUME [/var/lib/postgresql]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

ENTRYPOINT ["docker-entrypoint.sh"]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

STOPSIGNAL SIGINT

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

EXPOSE map[5432/tcp:{}]

2025-06-06 18:27:47 UTC (buildkit.dockerfile.v0)

CMD ["postgres"]

Danger Zone
Delete Tag

Please be careful as this will not just delete the reference but also the actual content!

For example when you have latest and v1.2.3 both pointing to the same image
the deletion of latest will also permanently remove v1.2.3.