镜像构建历史
# 2024-05-23 07:17:59 0.00B 设置默认要执行的命令
CMD ["redis-server"]
# 2024-05-23 07:17:59 0.00B 声明容器运行时监听的端口
EXPOSE map[6379/tcp:{}]
# 2024-05-23 07:17:59 0.00B 配置容器启动时运行的命令
ENTRYPOINT ["docker-entrypoint.sh"]
# 2024-05-23 07:17:59 661.00B 复制新文件或目录到容器中
COPY docker-entrypoint.sh /usr/local/bin/ # buildkit
# 2024-05-23 07:17:59 0.00B 设置工作目录为/data
WORKDIR /data
# 2024-05-23 07:17:59 0.00B 创建挂载点用于持久化数据或共享数据
VOLUME [/data]
# 2024-05-23 07:17:59 0.00B 执行命令并创建新的镜像层
RUN /bin/sh -c mkdir /data && chown redis:redis /data # buildkit
# 2024-05-23 07:17:59 30.00MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; apk add --no-cache --virtual .build-deps coreutils dpkg-dev dpkg gcc linux-headers make musl-dev openssl-dev wget ; 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; 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 }' )"; apk add --no-network --virtual .redis-rundeps $runDeps; apk del --no-network .build-deps; redis-cli --version; redis-server --version # buildkit
# 2024-05-23 07:17:59 0.00B 设置环境变量 REDIS_DOWNLOAD_SHA
ENV REDIS_DOWNLOAD_SHA=5981179706f8391f03be91d951acafaeda91af7fac56beffb2701963103e423d
# 2024-05-23 07:17:59 0.00B 设置环境变量 REDIS_DOWNLOAD_URL
ENV REDIS_DOWNLOAD_URL=http://download.redis.io/releases/redis-7.2.5.tar.gz
# 2024-05-23 07:17:59 0.00B 设置环境变量 REDIS_VERSION
ENV REDIS_VERSION=7.2.5
# 2024-05-23 07:17:59 2.41MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; apk add --no-cache --virtual .gosu-fetch gnupg; arch="$(apk --print-arch)"; case "$arch" in 'x86_64') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-amd64'; sha256='bbc4136d03ab138b1ad66fa4fc051bafc6cc7ffae632b069a53657279a450de3' ;; 'aarch64') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-arm64'; sha256='c3805a85d17f4454c23d7059bcb97e1ec1af272b90126e79ed002342de08389b' ;; 'armhf') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-armhf'; sha256='e5866286277ff2a2159fb9196fea13e0a59d3f1091ea46ddb985160b94b6841b' ;; 'x86') url='https://github.com/tianon/gosu/releases/download/1.17/gosu-i386'; sha256='087dbb8fe479537e64f9c86fa49ff3b41dee1cbd28739a19aaef83dc8186b1ca' ;; 'ppc64le') 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' ;; 'armv7') 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; apk del --no-network .gosu-fetch; chmod +x /usr/local/bin/gosu; gosu --version; gosu nobody true # buildkit
# 2024-05-23 07:17:59 0.00B 设置环境变量 GOSU_VERSION
ENV GOSU_VERSION=1.17
# 2024-05-23 07:17:59 514.78KB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; apk add --no-cache tzdata ; # buildkit
# 2024-05-23 07:17:59 3.06KB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; addgroup -S -g 1000 redis; adduser -S -G redis -u 999 redis # buildkit
# 2024-05-23 07:17:59 0.00B
/bin/sh -c #(nop) CMD ["/bin/sh"]
# 2024-05-23 07:17:59 7.80MB
/bin/sh -c #(nop) ADD file:33ebe56b967747a97dcec01bc2559962bee8823686c9739d26be060381bbb3ca in /
镜像信息
{
"Id": "sha256:38a44d79682281c78810ce4f57a9a6c65e2307a1c6c4c7719092814b1ab5170f",
"RepoTags": [
"redis:7.2.5-alpine",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/redis:7.2.5-alpine"
],
"RepoDigests": [
"redis@sha256:de14eedfbd1fc871d0f5aa1773fd80743930e45354d035b6f3b551e7ffa44df8",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/redis@sha256:2118bac80a6de38635c855c87fd9b60be15e91ac9b0e67d5a5852b4253f7ae9f"
],
"Parent": "",
"Comment": "buildkit.dockerfile.v0",
"Created": "2024-05-22T23:17:59Z",
"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.2.5",
"REDIS_DOWNLOAD_URL=http://download.redis.io/releases/redis-7.2.5.tar.gz",
"REDIS_DOWNLOAD_SHA=5981179706f8391f03be91d951acafaeda91af7fac56beffb2701963103e423d"
],
"Cmd": [
"redis-server"
],
"ArgsEscaped": true,
"Image": "",
"Volumes": {
"/data": {}
},
"WorkingDir": "/data",
"Entrypoint": [
"docker-entrypoint.sh"
],
"OnBuild": null,
"Labels": null
},
"Architecture": "amd64",
"Os": "linux",
"Size": 40723252,
"GraphDriver": {
"Data": {
"LowerDir": "/var/lib/docker/overlay2/8c2570c6ee198bba2c301b268b7ae5357a908116d3d704f39ab86175a67d09bd/diff:/var/lib/docker/overlay2/f3d3178ff78cfcd932d8b35da8fbdd8ac83ca09a5d600c5db0375d83f9b94ee3/diff:/var/lib/docker/overlay2/221f6038e170a8d7c15e16d9f25b77f1bcbaa314a6fc5d1d2901897b31f0f528/diff:/var/lib/docker/overlay2/a34fd3f007c1fde966a5953b8c2b96c2ca4917883419e42976dcfaac189d35ff/diff:/var/lib/docker/overlay2/dc7521dd7b83dd3a8a475b99e1d9150809d2f93959160484840779ea46de34e9/diff:/var/lib/docker/overlay2/11a5d7db3e02651fde1a27ece3aed5898c46482bf5d8d7ffdf940ca3566146a4/diff:/var/lib/docker/overlay2/984bb007f5969551b53fa1fce3296c2df39ab51a6831eab684250ac7efdbac0c/diff",
"MergedDir": "/var/lib/docker/overlay2/1ba29ecb35cbd874a7be902b605f708dc041c418553083203b8f4cff6e5fe328/merged",
"UpperDir": "/var/lib/docker/overlay2/1ba29ecb35cbd874a7be902b605f708dc041c418553083203b8f4cff6e5fe328/diff",
"WorkDir": "/var/lib/docker/overlay2/1ba29ecb35cbd874a7be902b605f708dc041c418553083203b8f4cff6e5fe328/work"
},
"Name": "overlay2"
},
"RootFS": {
"Type": "layers",
"Layers": [
"sha256:94e5f06ff8e3d4441dc3cd8b090ff38dc911bfa8ebdb0dc28395bc98f82f983f",
"sha256:d9b5f7b65b8c764c19ee394fc282a879f50f42c112d74d59e2542b9ffb8a251b",
"sha256:ce95a379dd79e42486d189287bbdfed58443b3be87e0dc3177877a5e352c5110",
"sha256:6b4d2b06e6ee3579854147465f420b5e1ff357bbe5dc07ffc5546cb9051be8bf",
"sha256:ad2d33775debe23c1d3797f732d82bdad80775b7e48f6525a850335aa84db03c",
"sha256:30ad4cdb67dd581f8215e49d2153145359d26bf6a9760ddcf545144ecefb9a1b",
"sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef",
"sha256:62f7eb1caf2063a3952508b25176be1e01f5a7be101d1896ecc65522ef428ecd"
]
},
"Metadata": {
"LastTagTime": "2024-07-19T14:04:38.581643828+08:00"
}
}