镜像构建历史
# 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 26.75MB 执行命令并创建新的镜像层
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=f7aab300407aaa005bc1a688e61287111f4ae13ed657ec50ef4ab529893ddc30
# 2025-01-07 00:14:31 0.00B 设置环境变量 REDIS_DOWNLOAD_URL
ENV REDIS_DOWNLOAD_URL=http://download.redis.io/releases/redis-6.2.17.tar.gz
# 2025-01-07 00:14:31 0.00B 设置环境变量 REDIS_VERSION
ENV REDIS_VERSION=6.2.17
# 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' '@1736726400'
镜像信息
{
"Id": "sha256:3c2b714a9eee1738f255fdd94c8f136cec12e057b582830272810400638a4b70",
"RepoTags": [
"redis:6.2.17",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/redis:6.2.17-linuxarm64"
],
"RepoDigests": [
"redis@sha256:5610a8ffeaf386ecc7b6c8f070662a7a9d01bc7eafe237152a7d16e05b84afc9",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/redis@sha256:c05c00c0af1e550f37560f09b2397dd03aa494cc7150455d6223b722bddb8b43"
],
"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=6.2.17",
"REDIS_DOWNLOAD_URL=http://download.redis.io/releases/redis-6.2.17.tar.gz",
"REDIS_DOWNLOAD_SHA=f7aab300407aaa005bc1a688e61287111f4ae13ed657ec50ef4ab529893ddc30"
],
"Cmd": [
"redis-server"
],
"Image": "",
"Volumes": {
"/data": {}
},
"WorkingDir": "/data",
"Entrypoint": [
"docker-entrypoint.sh"
],
"OnBuild": null,
"Labels": null
},
"Architecture": "arm64",
"Variant": "v8",
"Os": "linux",
"Size": 128028712,
"GraphDriver": {
"Data": {
"LowerDir": "/var/lib/docker/overlay2/9425df75a29a4f8efa4c41d1bc54fec24f0616710914463b6be586fcffa65a04/diff:/var/lib/docker/overlay2/77709cacafc3c1ada0c0b6f757404516c38c8b25396ec702748dbf586686275b/diff:/var/lib/docker/overlay2/7ab2ad74c1cc198e646ea2eb8c15be15ee281d9d98265b516ed51338bb5279d3/diff:/var/lib/docker/overlay2/846ac686fa5005ae216c1850cfed721d4bdf86269b00bcc52aefdf7646259b7f/diff:/var/lib/docker/overlay2/0ce24b7db3a31092ba08be82acbc961aefd723e5acc3bbd9f657e7431f12299d/diff:/var/lib/docker/overlay2/fa5282872a31c3b768c91aa80bbb29333a7d46e31609ffb11a273a4ea939eea1/diff:/var/lib/docker/overlay2/b1cac45b5ec6289ba71455a83c439c0b44271cc7d5698bb66ff391a15e9aa6da/diff",
"MergedDir": "/var/lib/docker/overlay2/f706ce849ade720c76676ab1d37f22fb9110b6fcca43eb55df9fb18f49ad9527/merged",
"UpperDir": "/var/lib/docker/overlay2/f706ce849ade720c76676ab1d37f22fb9110b6fcca43eb55df9fb18f49ad9527/diff",
"WorkDir": "/var/lib/docker/overlay2/f706ce849ade720c76676ab1d37f22fb9110b6fcca43eb55df9fb18f49ad9527/work"
},
"Name": "overlay2"
},
"RootFS": {
"Type": "layers",
"Layers": [
"sha256:6f51610e98184af12bb1cfab40f1ae13928363f1ea9aa19138467f09167e9809",
"sha256:a96e9f74050da93487829f17b02b2cf7626d7b03553c7f79aec1f3dfeef087c9",
"sha256:3f5ff5792fce3a465416fb4bcb3b14959b07edf60b9555480630d97c02fa43b5",
"sha256:80b70ddbf1025be0c075058698ecdc5b062a350756b80ceb4a7de312d873845f",
"sha256:b8e6d379c2cdc2e3fbc38dcb9f36ef9f909115f1ca0051801fe5da382904b011",
"sha256:6a5b5cc45240f10766932e6cf2c86dbea83da103c49597b6afb5dd847f98481d",
"sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef",
"sha256:447f20414788d50a75d1a28ca9ada15a93855915c09b2f3c601ca9a330b0479c"
]
},
"Metadata": {
"LastTagTime": "2025-01-17T11:14:12.106360115+08:00"
}
}