docker.io/postgres:15.6 linux/amd64

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

系统OS: debian 12.5 扫描引擎: Trivy 扫描时间: 2025-01-03 13:49

低危漏洞:117 中危漏洞:71 高危漏洞:60 严重漏洞:8

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

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

Containerd拉取命令

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

Shell快速替换命令

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

Ansible快速分发-Docker

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

Ansible快速分发-Containerd

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

镜像构建历史


# 2024-02-21 08:46:13  0.00B 设置默认要执行的命令
CMD ["postgres"]
                        
# 2024-02-21 08:46:13  0.00B 声明容器运行时监听的端口
EXPOSE map[5432/tcp:{}]
                        
# 2024-02-21 08:46:13  0.00B 设置停止容器时发送的系统调用信号
STOPSIGNAL SIGINT
                        
# 2024-02-21 08:46:13  0.00B 配置容器启动时运行的命令
ENTRYPOINT ["docker-entrypoint.sh"]
                        
# 2024-02-21 08:46:13  23.00B 执行命令并创建新的镜像层
RUN /bin/sh -c ln -sT docker-ensure-initdb.sh /usr/local/bin/docker-enforce-initdb.sh # buildkit
                        
# 2024-02-21 08:46:13  14.96KB 复制新文件或目录到容器中
COPY docker-entrypoint.sh docker-ensure-initdb.sh /usr/local/bin/ # buildkit
                        
# 2024-02-21 08:46:13  0.00B 创建挂载点用于持久化数据或共享数据
VOLUME [/var/lib/postgresql/data]
                        
# 2024-02-21 08:46:13  0.00B 执行命令并创建新的镜像层
RUN /bin/sh -c mkdir -p "$PGDATA" && chown -R postgres:postgres "$PGDATA" && chmod 1777 "$PGDATA" # buildkit
                        
# 2024-02-21 08:46:13  0.00B 设置环境变量 PGDATA
ENV PGDATA=/var/lib/postgresql/data
                        
# 2024-02-21 08:46:13  0.00B 执行命令并创建新的镜像层
RUN /bin/sh -c mkdir -p /var/run/postgresql && chown -R postgres:postgres /var/run/postgresql && chmod 3777 /var/run/postgresql # buildkit
                        
# 2024-02-21 08:46:13  59.44KB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; 	dpkg-divert --add --rename --divert "/usr/share/postgresql/postgresql.conf.sample.dpkg" "/usr/share/postgresql/$PG_MAJOR/postgresql.conf.sample"; 	cp -v /usr/share/postgresql/postgresql.conf.sample.dpkg /usr/share/postgresql/postgresql.conf.sample; 	ln -sv ../postgresql.conf.sample "/usr/share/postgresql/$PG_MAJOR/"; 	sed -ri "s!^#?(listen_addresses)\s*=\s*\S+.*!\1 = '*'!" /usr/share/postgresql/postgresql.conf.sample; 	grep -F "listen_addresses = '*'" /usr/share/postgresql/postgresql.conf.sample # buildkit
                        
# 2024-02-21 08:46:13  308.07MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -ex; 		export PYTHONDONTWRITEBYTECODE=1; 		dpkgArch="$(dpkg --print-architecture)"; 	aptRepo="[ signed-by=/usr/local/share/keyrings/postgres.gpg.asc ] http://apt.postgresql.org/pub/repos/apt/ bookworm-pgdg main $PG_MAJOR"; 	case "$dpkgArch" in 		amd64 | arm64 | ppc64el | s390x) 			echo "deb $aptRepo" > /etc/apt/sources.list.d/pgdg.list; 			apt-get update; 			;; 		*) 			echo "deb-src $aptRepo" > /etc/apt/sources.list.d/pgdg.list; 						savedAptMark="$(apt-mark showmanual)"; 						tempDir="$(mktemp -d)"; 			cd "$tempDir"; 						apt-get update; 			apt-get install -y --no-install-recommends dpkg-dev; 			echo "deb [ trusted=yes ] file://$tempDir ./" > /etc/apt/sources.list.d/temp.list; 			_update_repo() { 				dpkg-scanpackages . > Packages; 				apt-get -o Acquire::GzipIndexes=false update; 			}; 			_update_repo; 						nproc="$(nproc)"; 			export DEB_BUILD_OPTIONS="nocheck parallel=$nproc"; 			apt-get build-dep -y postgresql-common pgdg-keyring; 			apt-get source --compile postgresql-common pgdg-keyring; 			_update_repo; 			apt-get build-dep -y "postgresql-$PG_MAJOR=$PG_VERSION"; 			apt-get source --compile "postgresql-$PG_MAJOR=$PG_VERSION"; 									apt-mark showmanual | xargs apt-mark auto > /dev/null; 			apt-mark manual $savedAptMark; 						ls -lAFh; 			_update_repo; 			grep '^Package: ' Packages; 			cd /; 			;; 	esac; 		apt-get install -y --no-install-recommends postgresql-common; 	sed -ri 's/#(create_main_cluster) .*$/\1 = false/' /etc/postgresql-common/createcluster.conf; 	apt-get install -y --no-install-recommends 		"postgresql-$PG_MAJOR=$PG_VERSION" 	; 		rm -rf /var/lib/apt/lists/*; 		if [ -n "$tempDir" ]; then 		apt-get purge -y --auto-remove; 		rm -rf "$tempDir" /etc/apt/sources.list.d/temp.list; 	fi; 		find /usr -name '*.pyc' -type f -exec bash -c 'for pyc; do dpkg -S "$pyc" &> /dev/null || rm -vf "$pyc"; done' -- '{}' +; 		postgres --version # buildkit
                        
# 2024-02-21 08:46:13  0.00B 设置环境变量 PG_VERSION
ENV PG_VERSION=15.6-1.pgdg120+2
                        
# 2024-02-21 08:46:13  0.00B 设置环境变量 PATH
ENV PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/lib/postgresql/15/bin
                        
# 2024-02-21 08:46:13  0.00B 设置环境变量 PG_MAJOR
ENV PG_MAJOR=15
                        
# 2024-02-21 08:46:13  3.98KB 执行命令并创建新的镜像层
RUN /bin/sh -c set -ex; 	key='B97B0AFCAA1A47F044F244A07FCC7D46ACCC4CF8'; 	export GNUPGHOME="$(mktemp -d)"; 	mkdir -p /usr/local/share/keyrings/; 	gpg --batch --keyserver keyserver.ubuntu.com --recv-keys "$key"; 	gpg --batch --export --armor "$key" > /usr/local/share/keyrings/postgres.gpg.asc; 	gpgconf --kill all; 	rm -rf "$GNUPGHOME" # buildkit
                        
# 2024-02-21 08:46:13  0.00B 执行命令并创建新的镜像层
RUN /bin/sh -c mkdir /docker-entrypoint-initdb.d # buildkit
                        
# 2024-02-21 08:46:13  3.18MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; 	apt-get update; 	apt-get install -y --no-install-recommends 		libnss-wrapper 		xz-utils 		zstd 	; 	rm -rf /var/lib/apt/lists/* # buildkit
                        
# 2024-02-21 08:46:13  0.00B 设置环境变量 LANG
ENV LANG=en_US.utf8
                        
# 2024-02-21 08:46:13  25.20MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; 	if [ -f /etc/dpkg/dpkg.cfg.d/docker ]; then 		grep -q '/usr/share/locale' /etc/dpkg/dpkg.cfg.d/docker; 		sed -ri '/\/usr\/share\/locale/d' /etc/dpkg/dpkg.cfg.d/docker; 		! grep -q '/usr/share/locale' /etc/dpkg/dpkg.cfg.d/docker; 	fi; 	apt-get update; apt-get install -y --no-install-recommends locales; rm -rf /var/lib/apt/lists/*; 	echo 'en_US.UTF-8 UTF-8' >> /etc/locale.gen; 	locale-gen; 	locale -a | grep 'en_US.utf8' # buildkit
                        
# 2024-02-21 08:46:13  4.16MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; 	savedAptMark="$(apt-mark showmanual)"; 	apt-get update; 	apt-get install -y --no-install-recommends ca-certificates wget; 	rm -rf /var/lib/apt/lists/*; 	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; 	apt-mark auto '.*' > /dev/null; 	[ -z "$savedAptMark" ] || apt-mark manual $savedAptMark > /dev/null; 	apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; 	chmod +x /usr/local/bin/gosu; 	gosu --version; 	gosu nobody true # buildkit
                        
# 2024-02-21 08:46:13  0.00B 设置环境变量 GOSU_VERSION
ENV GOSU_VERSION=1.17
                        
# 2024-02-21 08:46:13  9.93MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -ex; 	apt-get update; 	apt-get install -y --no-install-recommends 		gnupg 		less 	; 	rm -rf /var/lib/apt/lists/* # buildkit
                        
# 2024-02-21 08:46:13  4.32KB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; 	groupadd -r postgres --gid=999; 	useradd -r -g postgres --uid=999 --home-dir=/var/lib/postgresql --shell=/bin/bash postgres; 	mkdir -p /var/lib/postgresql; 	chown -R postgres:postgres /var/lib/postgresql # buildkit
                        
# 2024-02-21 08:46:13  0.00B 
/bin/sh -c #(nop)  CMD ["bash"]
                        
# 2024-02-21 08:46:13  74.83MB 
/bin/sh -c #(nop) ADD file:4b1be1de1a1e5aa608c688cad2824587262081866180d7368feb79d33ca05953 in / 
                        
                    

镜像信息

{
    "Id": "sha256:bacb8d141d0d811b9a424b11ee36c723aaccce05d81acbbe540d1b54113802ee",
    "RepoTags": [
        "postgres:15.6",
        "swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres:15.6"
    ],
    "RepoDigests": [
        "postgres@sha256:1ebd963e5c598f944a4e9ba27de4c95289d663dcc73731025aa53c5254094d8f",
        "swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/postgres@sha256:744ba3a18bd5f22cd86cb170d8237e91c422cf6b2211d25e157c8cd327b94324"
    ],
    "Parent": "",
    "Comment": "buildkit.dockerfile.v0",
    "Created": "2024-02-21T00:46:13Z",
    "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:/usr/lib/postgresql/15/bin",
            "GOSU_VERSION=1.17",
            "LANG=en_US.utf8",
            "PG_MAJOR=15",
            "PG_VERSION=15.6-1.pgdg120+2",
            "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": 425451446,
    "GraphDriver": {
        "Data": {
            "LowerDir": "/var/lib/docker/overlay2/e9702da7375508d23294d05404fb401541b7ac830094db0daf2690732013d064/diff:/var/lib/docker/overlay2/cad65b65f30834e2c9804593c3ed8da3b65265a98ae57f850186d5b13f602a30/diff:/var/lib/docker/overlay2/9c133a413634b0bde3b69306fbd54163784282d68de02a3e7971df0b95dc53da/diff:/var/lib/docker/overlay2/21e80e7f046093a193dae88e2eec210da6a4e57be5269a0a8f618f6b025d19cf/diff:/var/lib/docker/overlay2/80843bcdd9d6b10089bb5d6aa6310ec2e3e00b991306985c52c9bfef7c2f6374/diff:/var/lib/docker/overlay2/513dcd20cfc6a52fb85bcaff2a93351c89978bcb8f3a63301af2040e94a01c61/diff:/var/lib/docker/overlay2/61cf2b33cd0578c74448a094789e5563cc4aa759d9bc5bdbded4d8227ccad622/diff:/var/lib/docker/overlay2/9a74d512e536cc260e0c7ac1dd15285b3151b6d701ebacd4d2d327be5fc858c5/diff:/var/lib/docker/overlay2/95582fff8f40171af617b9b8e524f53832b35de21e2631ab4ec905f3c9cef62b/diff:/var/lib/docker/overlay2/eb03230772423bf16e5f44109f6bad0a046b9b955a0c9b01e2cf3fd8f20e4ea1/diff:/var/lib/docker/overlay2/9803c0a6b708a8fd3673e037c926ed2c9413f42f557c023f79b8da06a007893e/diff:/var/lib/docker/overlay2/caf34c54a7268690de9dbdc13f00a0380cd12f6acc8606401c473b5c3b1a91dc/diff:/var/lib/docker/overlay2/992d0a9f6ca91f217fd532a08edef28d39999dcb088c1c0086948a589249aefc/diff",
            "MergedDir": "/var/lib/docker/overlay2/01e18785cbc7285c0e6d3ee6720754c2db56df33d17bcef01a86e7f302137a35/merged",
            "UpperDir": "/var/lib/docker/overlay2/01e18785cbc7285c0e6d3ee6720754c2db56df33d17bcef01a86e7f302137a35/diff",
            "WorkDir": "/var/lib/docker/overlay2/01e18785cbc7285c0e6d3ee6720754c2db56df33d17bcef01a86e7f302137a35/work"
        },
        "Name": "overlay2"
    },
    "RootFS": {
        "Type": "layers",
        "Layers": [
            "sha256:52ec5a4316fadc09a4a51f82b8d7b66ead0d71bea4f75e81e25b4094c4219061",
            "sha256:ab76f84e9b26422f8cd0a876825d813ce3651a9c4ef2dfed04601b3416adc3e4",
            "sha256:4a80f091d7b869a3a21001ea9bfe3980d12861054cf316e71019b18669bdb133",
            "sha256:817901da3f7ae6197f053d4e662fd0efc7720bfdd415f7e89de1226c4cdbf0d4",
            "sha256:ab4d8fb041f90004ea1a15c41bb4e22a739e275e72f4e672f20ad949297fef1e",
            "sha256:b4b6f2de36dc3b3997905d6732be9fcc6f4e79323b7a47d58f5b1e8bad8673e3",
            "sha256:3e7758425db3a33b0ef97e9c85ba2fcf7496790ab055f8802fb4d158e7d04b02",
            "sha256:23c54c9044fd00e420f613398736d88ece31b9b9f6c2e41f4b916bfc4880a36c",
            "sha256:297182cfcca729500cea3249735988b959b96998094033f248ee12bc9532a42d",
            "sha256:46d1e9d2d0816b6fbd8ba6d821c6c45b7fe1974e14fd9f9782ef5361fb63b022",
            "sha256:e45f5178f6822f3bbd46e2833fb539490456b0038dddb7db0b4973cb1a5fea25",
            "sha256:6e9cff5a956e8ed0ecf51a56e7280d93c0c928a444eae39e8b6b0eff0d7342d6",
            "sha256:9e6e59a0660443c9fde9caedc04dabdfb577d31a1d5f31fdb07eef64d4cdc308",
            "sha256:af4a9e23fa94b69287dd6eac0e83d24db64f8ae2056545701e33b3a29c8d4efc"
        ]
    },
    "Metadata": {
        "LastTagTime": "2025-01-03T13:48:58.504584079+08:00"
    }
}

更多版本

docker.io/postgres:12.19-bullseye

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

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
384

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
521

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
192

docker.io/postgres:14.2-alpine

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

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
272

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
234

docker.io/postgres:alpine

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

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
74

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
69

docker.io/postgres:16-alpine

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

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
55

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
40