镜像构建历史
# 2024-10-08 02:55:41 0.00B 设置默认要执行的命令
CMD ["python3"]
# 2024-10-08 02:55:41 36.00B 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; for src in idle3 pip3 pydoc3 python3 python3-config; do dst="$(echo "$src" | tr -d 3)"; [ -s "/usr/local/bin/$src" ]; [ ! -e "/usr/local/bin/$dst" ]; ln -svT "$src" "/usr/local/bin/$dst"; done # buildkit
# 2024-10-08 02:55:41 36.43MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; savedAptMark="$(apt-mark showmanual)"; apt-get update; apt-get install -y --no-install-recommends dpkg-dev gcc gnupg libbluetooth-dev libbz2-dev libc6-dev libdb-dev libexpat1-dev libffi-dev libgdbm-dev liblzma-dev libncursesw5-dev libreadline-dev libsqlite3-dev libssl-dev make tk-dev uuid-dev wget xz-utils zlib1g-dev ; wget -O python.tar.xz "https://www.python.org/ftp/python/${PYTHON_VERSION%%[a-z]*}/Python-$PYTHON_VERSION.tar.xz"; wget -O python.tar.xz.asc "https://www.python.org/ftp/python/${PYTHON_VERSION%%[a-z]*}/Python-$PYTHON_VERSION.tar.xz.asc"; GNUPGHOME="$(mktemp -d)"; export GNUPGHOME; gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys "$GPG_KEY"; gpg --batch --verify python.tar.xz.asc python.tar.xz; gpgconf --kill all; rm -rf "$GNUPGHOME" python.tar.xz.asc; mkdir -p /usr/src/python; tar --extract --directory /usr/src/python --strip-components=1 --file python.tar.xz; rm python.tar.xz; cd /usr/src/python; gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; ./configure --build="$gnuArch" --enable-loadable-sqlite-extensions --enable-optimizations --enable-option-checking=fatal --enable-shared --with-lto --with-system-expat --with-ensurepip ; nproc="$(nproc)"; EXTRA_CFLAGS="$(dpkg-buildflags --get CFLAGS)"; LDFLAGS="$(dpkg-buildflags --get LDFLAGS)"; LDFLAGS="${LDFLAGS:--Wl},--strip-all"; make -j "$nproc" "EXTRA_CFLAGS=${EXTRA_CFLAGS:-}" "LDFLAGS=${LDFLAGS:-}" "PROFILE_TASK=${PROFILE_TASK:-}" ; rm python; make -j "$nproc" "EXTRA_CFLAGS=${EXTRA_CFLAGS:-}" "LDFLAGS=${LDFLAGS:--Wl},-rpath='\$\$ORIGIN/../lib'" "PROFILE_TASK=${PROFILE_TASK:-}" python ; make install; cd /; rm -rf /usr/src/python; find /usr/local -depth \( \( -type d -a \( -name test -o -name tests -o -name idle_test \) \) -o \( -type f -a \( -name '*.pyc' -o -name '*.pyo' -o -name 'libpython*.a' \) \) \) -exec rm -rf '{}' + ; ldconfig; apt-mark auto '.*' > /dev/null; apt-mark manual $savedAptMark; find /usr/local -type f -executable -not \( -name '*tkinter*' \) -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; rm -rf /var/lib/apt/lists/*; export PYTHONDONTWRITEBYTECODE=1; python3 --version; pip3 --version # buildkit
# 2024-10-08 02:55:41 0.00B 设置环境变量 PYTHON_VERSION
ENV PYTHON_VERSION=3.13.0
# 2024-10-08 02:55:41 0.00B 设置环境变量 GPG_KEY
ENV GPG_KEY=7169605F62C751356D054A26A821E680E5FA6305
# 2024-10-08 02:55:41 3.11MB 执行命令并创建新的镜像层
RUN /bin/sh -c set -eux; apt-get update; apt-get install -y --no-install-recommends ca-certificates netbase tzdata ; rm -rf /var/lib/apt/lists/* # buildkit
# 2024-10-08 02:55:41 0.00B 设置环境变量 PATH
ENV PATH=/usr/local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
# 2024-10-08 02:55:41 0.00B
/bin/sh -c #(nop) CMD ["bash"]
# 2024-10-08 02:55:41 80.64MB
/bin/sh -c #(nop) ADD file:0f6f1b93a8fddd20b36a99cc6cfbe4a03bc7be2adb427f7f8e74a2029c54c8bb in /
镜像信息
{
"Id": "sha256:d83985831385f3e325d10e5772f7e8fafe326abb8fdee84c5ea9f3df5d5d3d07",
"RepoTags": [
"python:3.13.0-slim-bullseye",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/python:3.13.0-slim-bullseye"
],
"RepoDigests": [
"python@sha256:5306ec99dd5bdd64804dc0f5ec420bd4423cd63a4e0c48fa7827d2df213bbb4d",
"swr.cn-north-4.myhuaweicloud.com/ddn-k8s/docker.io/python@sha256:bf4c813bcc1b1bfb23218d9ef9a1901b6eb28fb95772a85db04dcdfc5d629f47"
],
"Parent": "",
"Comment": "buildkit.dockerfile.v0",
"Created": "2024-10-07T18:55:41Z",
"Container": "",
"ContainerConfig": null,
"DockerVersion": "",
"Author": "",
"Config": {
"Hostname": "",
"Domainname": "",
"User": "",
"AttachStdin": false,
"AttachStdout": false,
"AttachStderr": false,
"Tty": false,
"OpenStdin": false,
"StdinOnce": false,
"Env": [
"PATH=/usr/local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
"GPG_KEY=7169605F62C751356D054A26A821E680E5FA6305",
"PYTHON_VERSION=3.13.0"
],
"Cmd": [
"python3"
],
"ArgsEscaped": true,
"Image": "",
"Volumes": null,
"WorkingDir": "",
"Entrypoint": null,
"OnBuild": null,
"Labels": null
},
"Architecture": "amd64",
"Os": "linux",
"Size": 120180237,
"GraphDriver": {
"Data": {
"LowerDir": "/var/lib/docker/overlay2/00b743f3279257f3b8af3b968c359d15bf244cc9e1e134a34607325268e0b60d/diff:/var/lib/docker/overlay2/e7c29cd8382d0032deff4ea824f7368a89e716938023b8e38e0555605092f7b4/diff:/var/lib/docker/overlay2/1674dd100bbd94bdb637dbb650a7e578029badd353483e7e3d8acfee264cda60/diff",
"MergedDir": "/var/lib/docker/overlay2/c64e926758dd1bd8da3d115e2bc8427679a3863897045e4ac8b3ed76da82da59/merged",
"UpperDir": "/var/lib/docker/overlay2/c64e926758dd1bd8da3d115e2bc8427679a3863897045e4ac8b3ed76da82da59/diff",
"WorkDir": "/var/lib/docker/overlay2/c64e926758dd1bd8da3d115e2bc8427679a3863897045e4ac8b3ed76da82da59/work"
},
"Name": "overlay2"
},
"RootFS": {
"Type": "layers",
"Layers": [
"sha256:ceffe60ed7219cc3492bce3afb6877ba708349d497476faa561c63f89decfc5e",
"sha256:a5484a10bdb418857397b7880563a80a71c1ba56e2a7c787f4888637ed3a3be9",
"sha256:3a9583f01a75d39fc15b8a77e9cbf9c4817823216adcac1dc2518c3d427c2a2e",
"sha256:3d8b0fea4b6aa2fd1593c199b179e584ebb6b71905e4bd5c3bd6a354c5528f30"
]
},
"Metadata": {
"LastTagTime": "2024-10-17T14:13:02.413732217+08:00"
}
}