镜像构建历史
# 2025-01-07 00:14:31 0.00B 设置默认要执行的命令
CMD ["redis-server"]
# 2025-01-07 00:14:31 0.00B 声明容器运行时监听的端口
EXPOSE map[6379/tcp:{}]
# 2025-01-07 00:14:31 0.00B 配置容器启动时运行的命令
ENTRYPOINT ["docker-entrypoint.sh"]
# 2025-01-07 00:14:31 661.00B 复制新文件或目录到容器中
COPY docker-entrypoint.sh /usr/local/bin/ # buildkit
# 2025-01-07 00:14:31 0.00B 设置工作目录为/data
WORKDIR /data
# 2025-01-07 00:14:31 0.00B 创建挂载点用于持久化数据或共享数据
VOLUME [/data]
# 2025-01-07 00:14:31 0.00B 执行命令并创建新的镜像层
RUN /bin/sh -c mkdir /data && chown redis:redis /data # buildkit
# 2025-01-07 00:14:31 38.23MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; savedAptMark="$(apt-mark showmanual)"; apt-get update; apt-get install -y --no-install-recommends ca-certificates wget dpkg-dev gcc libc6-dev libssl-dev make ; rm -rf /var/lib/apt/lists/*; wget -O redis.tar.gz "$REDIS_DOWNLOAD_URL"; echo "$REDIS_DOWNLOAD_SHA *redis.tar.gz" | sha256sum -c -; mkdir -p /usr/src/redis; tar -xzf redis.tar.gz -C /usr/src/redis --strip-components=1; rm redis.tar.gz; grep -E '^ *createBoolConfig[(]"protected-mode",.*, *1 *,.*[)],$' /usr/src/redis/src/config.c; sed -ri 's!^( *createBoolConfig[(]"protected-mode",.*, *)1( *,.*[)],)$!\10\2!' /usr/src/redis/src/config.c; grep -E '^ *createBoolConfig[(]"protected-mode",.*, *0 *,.*[)],$' /usr/src/redis/src/config.c; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; extraJemallocConfigureFlags="--build=$gnuArch"; dpkgArch="$(dpkg --print-architecture)"; case "${dpkgArch##*-}" in amd64 | i386 | x32) extraJemallocConfigureFlags="$extraJemallocConfigureFlags --with-lg-page=12" ;; *) extraJemallocConfigureFlags="$extraJemallocConfigureFlags --with-lg-page=16" ;; esac; extraJemallocConfigureFlags="$extraJemallocConfigureFlags --with-lg-hugepage=21"; grep -F 'cd jemalloc && ./configure ' /usr/src/redis/deps/Makefile; sed -ri 's!cd jemalloc && ./configure !&'"$extraJemallocConfigureFlags"' !' /usr/src/redis/deps/Makefile; grep -F "cd jemalloc && ./configure $extraJemallocConfigureFlags " /usr/src/redis/deps/Makefile; export BUILD_TLS=yes; make -C /usr/src/redis -j "$(nproc)" all; make -C /usr/src/redis install; serverMd5="$(md5sum /usr/local/bin/redis-server | cut -d' ' -f1)"; export serverMd5; find /usr/local/bin/redis* -maxdepth 0 -type f -not -name redis-server -exec sh -eux -c ' md5="$(md5sum "$1" | cut -d" " -f1)"; test "$md5" = "$serverMd5"; ' -- '{}' ';' -exec ln -svfT 'redis-server' '{}' ';' ; rm -r /usr/src/redis; apt-mark auto '.*' > /dev/null; [ -z "$savedAptMark" ] || apt-mark manual $savedAptMark > /dev/null; find /usr/local -type f -executable -exec ldd '{}' ';' | awk '/=>/ { so = $(NF-1); if (index(so, "/usr/local/") == 1) { next }; gsub("^/(usr/)?", "", so); printf "*%s\n", so }' | sort -u | xargs -r dpkg-query --search | cut -d: -f1 | sort -u | xargs -r apt-mark manual ; apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; redis-cli --version; redis-server --version # buildkit
# 2025-01-07 00:14:31 0.00B 设置环境变量 REDIS_DOWNLOAD_SHA
ENV REDIS_DOWNLOAD_SHA=4ddebbf09061cbb589011786febdb34f29767dd7f89dbe712d2b68e808af6a1f
# 2025-01-07 00:14:31 0.00B 设置环境变量 REDIS_DOWNLOAD_URL
ENV REDIS_DOWNLOAD_URL=http://download.redis.io/releases/redis-7.4.2.tar.gz
# 2025-01-07 00:14:31 0.00B 设置环境变量 REDIS_VERSION
ENV REDIS_VERSION=7.4.2
# 2025-01-07 00:14:31 4.17MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; savedAptMark="$(apt-mark showmanual)"; apt-get update; apt-get install -y --no-install-recommends ca-certificates gnupg wget; rm -rf /var/lib/apt/lists/*; arch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; case "$arch" in 'amd64') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-amd64'; sha256='bbc4136d03ab138b1ad66fa4fc051bafc6cc7ffae632b069a53657279a450de3' ;; 'arm64') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-arm64'; sha256='c3805a85d17f4454c23d7059bcb97e1ec1af272b90126e79ed002342de08389b' ;; 'armel') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-armel'; sha256='f9969910fa141140438c998cfa02f603bf213b11afd466dcde8fa940e700945d' ;; 'i386') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-i386'; sha256='087dbb8fe479537e64f9c86fa49ff3b41dee1cbd28739a19aaef83dc8186b1ca' ;; 'mips64el') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-mips64el'; sha256='87140029d792595e660be0015341dfa1c02d1181459ae40df9f093e471d75b70' ;; 'ppc64el') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-ppc64el'; sha256='1891acdcfa70046818ab6ed3c52b9d42fa10fbb7b340eb429c8c7849691dbd76' ;; 'riscv64') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-riscv64'; sha256='38a6444b57adce135c42d5a3689f616fc7803ddc7a07ff6f946f2ebc67a26ba6' ;; 's390x') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-s390x'; sha256='69873bab588192f760547ca1f75b27cfcf106e9f7403fee6fd0600bc914979d0' ;; 'armhf') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-armhf'; sha256='e5866286277ff2a2159fb9196fea13e0a59d3f1091ea46ddb985160b94b6841b' ;; *) echo >&2 "error: unsupported gosu architecture: '$arch'"; exit 1 ;; esac; wget -O /usr/local/bin/gosu.asc "$url.asc"; wget -O /usr/local/bin/gosu "$url"; echo "$sha256 */usr/local/bin/gosu" | sha256sum -c -; 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
# 2025-01-07 00:14:31 0.00B 设置环境变量 GOSU_VERSION
ENV GOSU_VERSION=1.17
# 2025-01-07 00:14:31 5.08KB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; apt-get update; apt-get install -y --no-install-recommends tzdata ; rm -rf /var/lib/apt/lists/* # buildkit
# 2025-01-07 00:14:31 4.30KB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; groupadd -r -g 999 redis; useradd -r -g redis -u 999 redis # buildkit
# 2025-01-07 00:14:31 97.11MB
# debian.sh --arch 'arm64' out/ 'bookworm' '@1742169600'
镜像信息
{
"Id": "sha256:a8036f14f15ead9517115576fb4462894a000620c2be556410f6c24afb8a482b",
"RepoTags": [
"redis:7.4.2",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/redis:7.4.2-linuxarm64"
],
"RepoDigests": [
"redis@sha256:bd41d55aae1ecff61b2fafd0d66761223fe94a60373eb6bb781cfbb570a84079",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/redis@sha256:42f1d728f6b8d5774fd98bfb5fe481a3c762ec0bea2849860397dadb690a8732"
],
"Parent": "",
"Comment": "buildkit.dockerfile.v0",
"Created": "2025-01-06T16:14:31Z",
"Container": "",
"ContainerConfig": null,
"DockerVersion": "",
"Author": "",
"Config": {
"Hostname": "",
"Domainname": "",
"User": "",
"AttachStdin": false,
"AttachStdout": false,
"AttachStderr": false,
"ExposedPorts": {
"6379/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",
"REDIS_VERSION=7.4.2",
"REDIS_DOWNLOAD_URL=http://download.redis.io/releases/redis-7.4.2.tar.gz",
"REDIS_DOWNLOAD_SHA=4ddebbf09061cbb589011786febdb34f29767dd7f89dbe712d2b68e808af6a1f"
],
"Cmd": [
"redis-server"
],
"Image": "",
"Volumes": {
"/data": {}
},
"WorkingDir": "/data",
"Entrypoint": [
"docker-entrypoint.sh"
],
"OnBuild": null,
"Labels": null
},
"Architecture": "arm64",
"Variant": "v8",
"Os": "linux",
"Size": 139518169,
"GraphDriver": {
"Data": {
"LowerDir": "/var/lib/docker/overlay2/87b888b0f500090adf6b98cc91d358d3487ba3f78805944f86cd5484961c7ece/diff:/var/lib/docker/overlay2/7720008997d870a9f97f74040246174bead3ee69bd0a6e60160ed5d8a2962fe6/diff:/var/lib/docker/overlay2/de457376c03f73e0a1b3fafd4f34e945517851cae0479a33a0229c97435ba0e5/diff:/var/lib/docker/overlay2/dbd7b580324b28c03f0ae65bef4f42a8f02f021c3d42b3b52560d130ccc6d0c8/diff:/var/lib/docker/overlay2/2c6f438277ea2a45fd5890cf9692087ab87c8517c91102006a2154737ea59d51/diff:/var/lib/docker/overlay2/f1df13415da9fac99cc5b2b0386e88d0c3d277f350e0e084dcf5ad0881a936d9/diff:/var/lib/docker/overlay2/942eb91f433cb72c1751ea0da204c051788648bcdd86c57a2250253ecfd02ec0/diff",
"MergedDir": "/var/lib/docker/overlay2/a9c5324c00718c8cc79dd239c6eec37611f4759e4daf481e612d881df86b8b20/merged",
"UpperDir": "/var/lib/docker/overlay2/a9c5324c00718c8cc79dd239c6eec37611f4759e4daf481e612d881df86b8b20/diff",
"WorkDir": "/var/lib/docker/overlay2/a9c5324c00718c8cc79dd239c6eec37611f4759e4daf481e612d881df86b8b20/work"
},
"Name": "overlay2"
},
"RootFS": {
"Type": "layers",
"Layers": [
"sha256:70a3ee4d4d38a5bb57ecd08c40c9a37d750d3f8f63591e97cdbf8277c3698e6f",
"sha256:6ff3b68bb9e569ad0eb12b5bed3e46707ee80431c6e2d1b0f57a5c7b85d90cd6",
"sha256:ae99c56bee677be1ca0a83fd3f2c4e390a62c44654a3c20ac1c10ea8b8c13069",
"sha256:f1be0a5457285046cf0a19c37720d9719ce5056aca85e009174e106cf94b7902",
"sha256:eddbbcf70703d1d85c487797633cf51f5717d7a468f1f8243b6d7b7ebb3a98a4",
"sha256:7656815b370363ef48031a72b80c6a032325ec189c41194688eff1c0da289221",
"sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef",
"sha256:b57af54de8bfaf9df576db0279b023f9815ba98c9d966a8ccfc703d8670593eb"
]
},
"Metadata": {
"LastTagTime": "2025-04-02T09:14:49.13812187+08:00"
}
}