docker.io/postgres:16-alpine linux/amd64

docker.io/postgres:16-alpine - 国内下载镜像源 浏览次数:115 安全受验证的发布者-Postgres
PostgreSQL 是一个开源的关系数据库管理系统(RDBMS),提供了传输控制协议(TCP)上的 PostgreSQL 服务。该镜像支持多种操作系统和存储引擎,方便开发、测试和部署应用程序。
源镜像 docker.io/postgres:16-alpine
国内镜像 swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine
镜像ID sha256:d520655e8467285fa28a07c223fa93941dbe1afd03e1a03bb8888e9bb897d7f0
镜像TAG 16-alpine
大小 250.73MB
镜像源 docker.io
项目信息 Docker-Hub主页 🚀项目TAG 🚀
CMD postgres
启动入口 docker-entrypoint.sh
工作目录 /
OS/平台 linux/amd64
浏览量 115 次
贡献者
镜像创建 2024-11-21T20:14:24Z
同步时间 2024-12-03 21:04
更新时间 2025-01-17 13:10
开放端口
5432/tcp
环境变量
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin GOSU_VERSION=1.17 LANG=en_US.utf8 PG_MAJOR=16 PG_VERSION=16.6 PG_SHA256=23369cdaccd45270ac5dcc30fa9da205d5be33fa505e1f17a0418d2caeca477b DOCKER_PG_LLVM_DEPS=llvm15-dev clang15 PGDATA=/var/lib/postgresql/data
镜像安全扫描 查看Trivy扫描报告

系统OS: alpine 3.20.3 扫描引擎: Trivy 扫描时间: 2024-12-03 21:05

低危漏洞:1 中危漏洞:21 高危漏洞:30 严重漏洞:3

Docker拉取命令 无权限下载?点我修复

docker pull swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine
docker tag  swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine  docker.io/postgres:16-alpine

Containerd拉取命令

ctr images pull swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine
ctr images tag  swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine  docker.io/postgres:16-alpine

Shell快速替换命令

sed -i 's#postgres:16-alpine#swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine#' deployment.yaml

Ansible快速分发-Docker

#ansible k8s -m shell -a 'docker pull swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine && docker tag  swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine  docker.io/postgres:16-alpine'

Ansible快速分发-Containerd

#ansible k8s -m shell -a 'ctr images pull swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine && ctr images tag  swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine  docker.io/postgres:16-alpine'

镜像构建历史


# 2024-11-22 04:14:24  0.00B 设置默认要执行的命令
CMD ["postgres"]
                        
# 2024-11-22 04:14:24  0.00B 声明容器运行时监听的端口
EXPOSE map[5432/tcp:{}]
                        
# 2024-11-22 04:14:24  0.00B 设置停止容器时发送的系统调用信号
STOPSIGNAL SIGINT
                        
# 2024-11-22 04:14:24  0.00B 配置容器启动时运行的命令
ENTRYPOINT ["docker-entrypoint.sh"]
                        
# 2024-11-22 04:14:24  23.00B 执行命令并创建新的镜像层
RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit
                        
# 2024-11-22 04:14:24  14.96KB 复制新文件或目录到容器中
COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit
                        
# 2024-11-22 04:14:24  0.00B 创建挂载点用于持久化数据或共享数据
VOLUME [/var/lib/postgresql/data]
                        
# 2024-11-22 04:14:24  0.00B 执行命令并创建新的镜像层
RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 1777 "$PGDATA" # buildkit
                        
# 2024-11-22 04:14:24  0.00B 设置环境变量 PGDATA
ENV PGDATA=/var/lib/postgresql/data
                        
# 2024-11-22 04:14:24  0.00B 执行命令并创建新的镜像层
RUN /bin/sh -c install --verbose --directory --owner postgres --group postgres --mode 3777 /var/run/postgresql # buildkit
                        
# 2024-11-22 04:14:24  59.25KB 执行命令并创建新的镜像层
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
                        
# 2024-11-22 04:14:24  240.25MB 执行命令并创建新的镜像层
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)"; 	wget -O config/config.guess 'https://git.savannah.gnu.org/cgit/config.git/plain/config.guess?id=7d3d27baf8107b630586c962c057e22149653deb'; 	wget -O config/config.sub 'https://git.savannah.gnu.org/cgit/config.git/plain/config.sub?id=7d3d27baf8107b630586c962c057e22149653deb'; 		export LLVM_CONFIG="/usr/lib/llvm15/bin/llvm-config"; 	export CLANG=clang-15; 		./configure 		--enable-option-checking=fatal 		--build="$gnuArch" 		--enable-integer-datetimes 		--enable-thread-safety 		--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
                        
# 2024-11-22 04:14:24  0.00B 设置环境变量 DOCKER_PG_LLVM_DEPS
ENV DOCKER_PG_LLVM_DEPS=llvm15-dev 		clang15
                        
# 2024-11-22 04:14:24  0.00B 设置环境变量 PG_SHA256
ENV PG_SHA256=23369cdaccd45270ac5dcc30fa9da205d5be33fa505e1f17a0418d2caeca477b
                        
# 2024-11-22 04:14:24  0.00B 设置环境变量 PG_VERSION
ENV PG_VERSION=16.6
                        
# 2024-11-22 04:14:24  0.00B 设置环境变量 PG_MAJOR
ENV PG_MAJOR=16
                        
# 2024-11-22 04:14:24  0.00B 执行命令并创建新的镜像层
RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit
                        
# 2024-11-22 04:14:24  0.00B 设置环境变量 LANG
ENV LANG=en_US.utf8
                        
# 2024-11-22 04:14:24  4.00B 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; ln -svf gosu /usr/local/bin/su-exec; su-exec nobody true # backwards compatibility (removed in PostgreSQL 17+) # buildkit
                        
# 2024-11-22 04:14:24  2.60MB 执行命令并创建新的镜像层
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
                        
# 2024-11-22 04:14:24  0.00B 设置环境变量 GOSU_VERSION
ENV GOSU_VERSION=1.17
                        
# 2024-11-22 04:14:24  3.07KB 执行命令并创建新的镜像层
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
                        
# 2024-09-06 20:05:36  0.00B 设置默认要执行的命令
CMD ["/bin/sh"]
                        
# 2024-09-06 20:05:36  7.80MB 复制文件或目录到容器中
ADD alpine-minirootfs-3.20.3-x86_64.tar.gz / # buildkit
                        
                    

镜像信息

{
    "Id": "sha256:d520655e8467285fa28a07c223fa93941dbe1afd03e1a03bb8888e9bb897d7f0",
    "RepoTags": [
        "postgres:16-alpine",
        "swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:16-alpine"
    ],
    "RepoDigests": [
        "postgres@sha256:52bba373df3c13594014b5e9ccc9f3c2cdb2221d50db1a91ec64570819f18aba",
        "swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres@sha256:9b3f56e1715f495e49f360e12bf567ade078d2bf0f6f0dc04560f600d047b8a8"
    ],
    "Parent": "",
    "Comment": "buildkit.dockerfile.v0",
    "Created": "2024-11-21T20:14:24Z",
    "Container": "",
    "ContainerConfig": null,
    "DockerVersion": "",
    "Author": "",
    "Config": {
        "Hostname": "",
        "Domainname": "",
        "User": "",
        "AttachStdin": false,
        "AttachStdout": false,
        "AttachStderr": false,
        "ExposedPorts": {
            "5432/tcp": {}
        },
        "Tty": false,
        "OpenStdin": false,
        "StdinOnce": false,
        "Env": [
            "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
            "GOSU_VERSION=1.17",
            "LANG=en_US.utf8",
            "PG_MAJOR=16",
            "PG_VERSION=16.6",
            "PG_SHA256=23369cdaccd45270ac5dcc30fa9da205d5be33fa505e1f17a0418d2caeca477b",
            "DOCKER_PG_LLVM_DEPS=llvm15-dev \t\tclang15",
            "PGDATA=/var/lib/postgresql/data"
        ],
        "Cmd": [
            "postgres"
        ],
        "ArgsEscaped": true,
        "Image": "",
        "Volumes": {
            "/var/lib/postgresql/data": {}
        },
        "WorkingDir": "/",
        "Entrypoint": [
            "docker-entrypoint.sh"
        ],
        "OnBuild": null,
        "Labels": null,
        "StopSignal": "SIGINT"
    },
    "Architecture": "amd64",
    "Os": "linux",
    "Size": 250728116,
    "GraphDriver": {
        "Data": {
            "LowerDir": "/var/lib/docker/overlay2/6dc82b6e3129b0b027f7d89faf1fd8d7096c033aff5b606c2ede90256f4e8e04/diff:/var/lib/docker/overlay2/d115c62d678505fbec7817522b2cb12f64facc2e0a6aaf0ec9d6c1ab108dc203/diff:/var/lib/docker/overlay2/c749b94e932cc8dc50d565a3329808e6fb9e52926b9aee3ec7f58257aade9ce7/diff:/var/lib/docker/overlay2/fee8197630bb6b4ea1779d973814b654f2eb404550f606652926498b6d589b2b/diff:/var/lib/docker/overlay2/a695e935e9755fcc1e63c2b0eb32919d6ef25b5ddf6b878e71d5fe3d30dbeabb/diff:/var/lib/docker/overlay2/f8f213d4705c9dbfd4251f5c8b8b6872a1189847f5d2d935817569fa9a90c55d/diff:/var/lib/docker/overlay2/8193755d429855abb106d8d35488dc46bdf4a3bf0c5d998363956d59fd871034/diff:/var/lib/docker/overlay2/577bb21259fc4d1513e8537244b1e3b863efca78321c0b1e3a30d3feba13db97/diff:/var/lib/docker/overlay2/69f367d6cc63fabb0812bfa06e512c9d6d05d9076de2249cb6c88bb0bcb8fd8e/diff:/var/lib/docker/overlay2/23c5724f3a35122d45237c48d0eec74bfb90f129834f1ecb674937c0af9f9db3/diff",
            "MergedDir": "/var/lib/docker/overlay2/4aa141a5986998d02d45a4601f9c1d8eb15fd52329f94f97c9de62567716bccf/merged",
            "UpperDir": "/var/lib/docker/overlay2/4aa141a5986998d02d45a4601f9c1d8eb15fd52329f94f97c9de62567716bccf/diff",
            "WorkDir": "/var/lib/docker/overlay2/4aa141a5986998d02d45a4601f9c1d8eb15fd52329f94f97c9de62567716bccf/work"
        },
        "Name": "overlay2"
    },
    "RootFS": {
        "Type": "layers",
        "Layers": [
            "sha256:75654b8eeebd3beae97271a102f57cdeb794cc91e442648544963a7e951e9558",
            "sha256:1bf4a338d38d9fa5f5cedb14afcc120bc26fe7d482fdf6d60ac1a7c8ce7bd0fc",
            "sha256:316493caa3e4423e78940f7e1689a4516ebc65e9a5ea73087080dc08943ef33b",
            "sha256:362cefeafd91f9d93348964a66ede328132e8ba1676e47e7136d912b8721a188",
            "sha256:b25415909b405c1f326a024f636d247353ff266da3d0628ed0f9cf252755eb86",
            "sha256:d735f8864e6f37bc806baf0c34dda3faca428b056a3d17a07f4bedc0cd11a84b",
            "sha256:501ebcee36b4871c6fe3b7f6d54637c11beb3463b927eac4eb6aa299da2d22c5",
            "sha256:900f870e3f1493a892b60afba279efdc87a5a5ed5f823bee4efb0a8d810c858e",
            "sha256:4908786b53176887f9ca50b269eacf5b68ce5c903c024db0a44508b20908c8f0",
            "sha256:f22d4ad18f1e66027b0d893af035422d57aff97deca6753fdeaafcf2b059f4cf",
            "sha256:ce50715dfcef8630e5fd99e1c8bc8883e68c5f3c8e9b9cde16025441ea6b0f21"
        ]
    },
    "Metadata": {
        "LastTagTime": "2024-12-03T21:03:42.457461325+08:00"
    }
}

更多版本

docker.io/postgres:12.19-bullseye

linux/amd64 docker.io386.93MB2024-06-16 13:12
357

docker.io/postgres:15-alpine

linux/amd64 docker.io248.31MB2024-06-19 17:31
1084

docker.io/postgres:12.19-alpine3.20

linux/amd64 docker.io236.26MB2024-06-28 17:32
228

docker.io/postgres:16.3-alpine3.20

linux/amd64 docker.io244.93MB2024-06-28 17:32
494

docker.io/postgres:14-alpine

linux/amd64 docker.io241.40MB2024-07-03 23:43
383

docker.io/postgres:15-alpine

linux/arm64 docker.io250.04MB2024-07-08 15:04
867

docker.io/postgres:15.4

linux/amd64 docker.io410.61MB2024-07-18 12:35
820

docker.io/postgres:9.6.21-alpine

linux/arm64 docker.io35.93MB2024-07-24 11:50
200

docker.io/postgres:13.8

linux/arm64 docker.io354.23MB2024-07-24 23:02
294

docker.io/postgres:16

linux/amd64 docker.io431.58MB2024-07-26 18:25
520

docker.io/postgres:9.6.24

linux/amd64 docker.io199.69MB2024-08-01 16:37
422

docker.io/postgres:15.3

linux/arm64 docker.io433.16MB2024-08-01 16:55
291

docker.io/postgres:16.3

linux/amd64 docker.io431.58MB2024-08-02 14:29
297

docker.io/postgres:16.3-bookworm

linux/amd64 docker.io431.58MB2024-08-08 17:41
191

docker.io/postgres:14.2-alpine

linux/amd64 docker.io210.71MB2024-08-15 15:18
200

docker.io/postgres:16.4

linux/amd64 docker.io431.68MB2024-08-27 17:28
508

docker.io/postgres:12.2

linux/amd64 docker.io313.75MB2024-09-13 17:25
238

docker.io/postgres:17

linux/amd64 docker.io434.31MB2024-10-01 13:14
356

docker.io/postgres:17-alpine

linux/amd64 docker.io248.16MB2024-10-03 21:57
271

docker.io/postgres:14.12

linux/amd64 docker.io421.93MB2024-10-14 14:43
163

docker.io/postgres:13.14

linux/amd64 docker.io419.14MB2024-10-15 10:01
312

docker.io/postgres:10-alpine

linux/amd64 docker.io79.09MB2024-10-15 20:03
233

docker.io/postgres:alpine

linux/amd64 docker.io248.16MB2024-10-24 11:56
318

docker.io/postgres:14.7-alpine3.17

linux/amd64 docker.io241.71MB2024-10-29 17:41
292

docker.io/postgres:14.11

linux/amd64 docker.io421.97MB2024-11-05 19:40
94

docker.io/postgres:12.3

linux/amd64 docker.io313.02MB2024-11-07 08:48
84

docker.io/postgres:12

linux/amd64 docker.io418.59MB2024-11-09 11:00
73

docker.io/postgres:9.5

linux/amd64 docker.io197.21MB2024-11-22 11:45
78

docker.io/postgres:11

linux/amd64 docker.io284.46MB2024-11-27 14:14
68

docker.io/postgres:16-alpine

linux/amd64 docker.io250.73MB2024-12-03 21:04
114

docker.io/postgres:9.6.16

linux/amd64 docker.io249.61MB2024-12-04 12:56
82

docker.io/postgres:12.4

linux/arm64 docker.io299.56MB2024-12-19 18:46
58

docker.io/postgres:17.2

linux/amd64 docker.io434.77MB2024-12-19 19:20
97

docker.io/postgrest/postgrest:v12.0.1

linux/amd64 docker.io17.42MB2024-12-24 10:07
60

docker.io/postgres:16.6-alpine3.21

linux/amd64 docker.io274.85MB2024-12-30 14:08
54

docker.io/postgres:15.6

linux/amd64 docker.io425.45MB2025-01-03 13:48
31

docker.io/postgres:13-alpine

linux/amd64 docker.io267.85MB2025-01-03 14:51
32

docker.io/postgres:17.2-alpine3.21

linux/amd64 docker.io277.63MB2025-01-07 14:18
39