镜像构建历史
# 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 19.34MB 执行命令并创建新的镜像层
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=34e74856cbd66fdb3a684fb349d93961d8c7aa668b06f81fd93ff267d09bc277
# 2024-05-23 07:17:59 0.00B 设置环境变量 REDIS_DOWNLOAD_URL
ENV REDIS_DOWNLOAD_URL=http://download.redis.io/releases/redis-6.2.14.tar.gz
# 2024-05-23 07:17:59 0.00B 设置环境变量 REDIS_VERSION
ENV REDIS_VERSION=6.2.14
# 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 496.06KB 执行命令并创建新的镜像层
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:5758b97d8301c84a204a6e516241275d785a7cade40b2fb99f01fe122482e283 in /
镜像信息
{
"Id": "sha256:7de0dedd123b8cb2b105ace4e8d00b8bba5ad7be39617dfa229acff315fe4fbf",
"RepoTags": [
"redis:6.2-alpine",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/library/redis:6.2-alpine"
],
"RepoDigests": [
"redis@sha256:2d1463258f2764328496376f5d965f20c6a67f66ea2b06dc42af351f75248792",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/library/redis@sha256:a5f59535378f82d2d284b39606b80c0da69b05da91545cb599e8ddf24e82c250"
],
"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=6.2.14",
"REDIS_DOWNLOAD_URL=http://download.redis.io/releases/redis-6.2.14.tar.gz",
"REDIS_DOWNLOAD_SHA=34e74856cbd66fdb3a684fb349d93961d8c7aa668b06f81fd93ff267d09bc277"
],
"Cmd": [
"redis-server"
],
"ArgsEscaped": true,
"Image": "",
"Volumes": {
"/data": {}
},
"WorkingDir": "/data",
"Entrypoint": [
"docker-entrypoint.sh"
],
"OnBuild": null,
"Labels": null
},
"Architecture": "amd64",
"Os": "linux",
"Size": 30048838,
"GraphDriver": {
"Data": {
"LowerDir": "/var/lib/docker/overlay2/70ea21df68ddaf00a9216ffd0009bca99dac238d7e74e6b94be42ad188a7fcaf/diff:/var/lib/docker/overlay2/3d38277b7437b3a8791562842226751ec4a2d76316de9ac043ffeb480fd020b0/diff:/var/lib/docker/overlay2/0d926eb4c8aed0850b7988140f51f11297770546e1abfc5dbb47201442d8c2f4/diff:/var/lib/docker/overlay2/a630fb27bb62cc4382d9a6ce190fcc4f95b6b782ed9382d58b7b51e9e30b2285/diff:/var/lib/docker/overlay2/acd58de088aad2e391d2c2da8b3bffd84fe0cb2326a921d633a14798549c508f/diff:/var/lib/docker/overlay2/12f8eba12018bd4c8e67717193dd560fe541f73e8f3e24d9f3068b10c7390c15/diff:/var/lib/docker/overlay2/56dbc2212cbc9b991b1a93a72a8c08a3a8460c06576fe4f3267009446334aa65/diff",
"MergedDir": "/var/lib/docker/overlay2/59ff74ee6ae2227dc1cfc592c15a4b52586927cba442028f6cb9a8bee624f943/merged",
"UpperDir": "/var/lib/docker/overlay2/59ff74ee6ae2227dc1cfc592c15a4b52586927cba442028f6cb9a8bee624f943/diff",
"WorkDir": "/var/lib/docker/overlay2/59ff74ee6ae2227dc1cfc592c15a4b52586927cba442028f6cb9a8bee624f943/work"
},
"Name": "overlay2"
},
"RootFS": {
"Type": "layers",
"Layers": [
"sha256:63ca1fbb43ae5034640e5e6cb3e083e05c290072c5366fcaa9d62435a4cced85",
"sha256:1e7c65db6accbbffc3705208097eedc7da6ab0e99fb456dabe53b172d4687c06",
"sha256:81c893aae3abc19ec70e37b4ffa72b0f2f0f21658153ee0512be3f0a3d0942ca",
"sha256:596215c9297342b39c310b5db8d2ee033976d09eb301c7d9107a9c78570a81ef",
"sha256:be940f9b0df40286541b4f6e1f93e10196942ebb3dc102a89f4074846f7bd143",
"sha256:9808869a894a90151473f45211aa981c02eabd2cbb5e872881788f1a91c53af2",
"sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef",
"sha256:257c09c92bb1ca08db0b896d2efdf084cb19ec0160547fcc39028208ac8934c4"
]
},
"Metadata": {
"LastTagTime": "2024-10-07T16:46:46.962756038+08:00"
}
}