Debian是一个完全由自由和开源软件组成的Linux发行版。
Debian (arm64v8) Docker镜像文档
镜像概述
关于Debian
Debian是一款主要由自由开源软件组成的操作系统,大部分软件采用GNU通用公共许可证授权,由Debian项目组开发维护。作为最流行的Linux发行版之一,Debian广泛应用于个人计算机和网络服务器,并被用作多个其他Linux发行版的基础。
***: Debian
本镜像说明
注意:本仓库是https://hub.docker.com/_/debian的`arm64v8`架构专用仓库。更多信息请参见官方镜像文档中的https://github.com/docker-library/official-images#architectures-other-than-amd64和官方镜像FAQ中的https://github.com/docker-library/faq#an-images-source-changed-in-git-now-what。
本镜像旨在提供最小化的Debian环境(容器的不可变/分层特性决定了添加内容比删除更简单)。具体而言,镜像基于https://manpages.debian.org/stable/debootstrap/debootstrap.8.en.html#variant=minbase_buildd_fakechroot构建,仅包含“必需”软件包,在保持“Debian”特性(由Debian发布团队和FTP团队定义管理)的同时实现最小镜像体积。
核心功能与特性
- 最小化基础镜像:基于
minbase变体构建,仅包含运行Debian所需的核心组件,减少镜像体积 - 多架构支持:除arm64v8外,还支持amd64、arm32v5、arm32v7、i386等多种架构
- 可重现构建:使用https://github.com/debuerreotype/debuerreotype工具构建,确保镜像生成过程透明可重现
- 官方镜像源:默认使用https://deb.debian.org CDN镜像源,兼顾可靠性与访问速度
- 滚动更新支持:提供stable、testing、unstable等滚动发布版本标签,满足不同稳定性需求
- 变体选择:提供标准版与slim版(移除文档、man pages等非必要文件),适应不同场景需求
支持的标签及Dockerfile链接
| 标签 | Dockerfile链接 |
|---|---|
bookworm, bookworm-20250929, 12.12, 12 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/bookworm/oci/index.json |
bookworm-backports | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/bookworm/backports/Dockerfile |
bookworm-slim, bookworm-20250929-slim, 12.12-slim, 12-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/bookworm/slim/oci/index.json |
bullseye, bullseye-20250929, 11.11, 11 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/bullseye/oci/index.json |
bullseye-slim, bullseye-20250929-slim, 11.11-slim, 11-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/bullseye/slim/oci/index.json |
experimental, experimental-20250929 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/experimental/Dockerfile |
forky, forky-20250929 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/forky/oci/index.json |
forky-backports | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/forky/backports/Dockerfile |
forky-slim, forky-20250929-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/forky/slim/oci/index.json |
oldoldstable, oldoldstable-20250929 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/oldoldstable/oci/index.json |
oldoldstable-slim, oldoldstable-20250929-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/oldoldstable/slim/oci/index.json |
oldstable, oldstable-20250929 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/oldstable/oci/index.json |
oldstable-backports | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/oldstable/backports/Dockerfile |
oldstable-slim, oldstable-20250929-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/oldstable/slim/oci/index.json |
rc-buggy, rc-buggy-20250929 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/rc-buggy/Dockerfile |
sid, sid-20250929 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/sid/oci/index.json |
sid-slim, sid-20250929-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/sid/slim/oci/index.json |
stable, stable-20250929 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/stable/oci/index.json |
stable-backports | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/stable/backports/Dockerfile |
stable-slim, stable-20250929-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/stable/slim/oci/index.json |
testing, testing-20250929 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/testing/oci/index.json |
testing-backports | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/testing/backports/Dockerfile |
testing-slim, testing-20250929-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/testing/slim/oci/index.json |
trixie, trixie-20250929, 13.1, 13, latest | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/trixie/oci/index.json |
trixie-backports | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/trixie/backports/Dockerfile |
trixie-slim, trixie-20250929-slim, 13.1-slim, 13-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/trixie/slim/oci/index.json |
unstable, unstable-20250929 | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/unstable/oci/index.json |
unstable-slim, unstable-20250929-slim | https://github.com/debuerreotype/docker-debian-artifacts/blob/c9cee6d8b5bdb18e48baea7195cb5054e3d2d4a2/unstable/slim/oci/index.json |
使用场景
开发环境
作为本地开发环境的基础镜像,提供标准化的Debian系统环境,确保开发与生产环境一致性。
应用部署基础
作为各类应用(如Web服务、数据库、中间件)的基础镜像,通过Dockerfile构建包含应用依赖的定制镜像。
CI/CD流程
在持续集成/持续部署流程中作为构建或测试环境,提供轻量、一致的运行时环境。
学习与测试
用于学习Debian系统操作、测试软件在不同Debian版本上的兼容性。
嵌入式系统
针对arm64v8架构,适合作为嵌入式设备(如树莓派、边缘计算设备)的应用容器基础。
使用方法与配置说明
基本操作
拉取镜像
bashdocker pull docker.xuanyuan.run/arm64v8/debian:latest # 拉取最新稳定版 docker pull docker.xuanyuan.run/arm64v8/debian:12-slim # 拉取Debian 12 slim版 docker pull docker.xuanyuan.run/arm64v8/debian:testing # 拉取测试版
运行交互式容器
bashdocker run -it --rm docker.xuanyuan.run/arm64v8/debian:latest bash # 启动临时交互式shell
运行后台容器
bashdocker run -d --name debian-base docker.xuanyuan.run/arm64v8/debian:stable # 后台运行容器 docker exec -it debian-base bash # 进入运行中的容器
配置 locales
本镜像默认仅包含C、C.UTF-8和POSIX三种locales。对于大多数UTF-8需求,C.UTF-8已足够,可通过环境变量配置:
bashdocker run -it --rm -e LANG=C.UTF-8 docker.xuanyuan.run/arm64v8/debian:latest bash
如需其他locale(如en_US.UTF-8),需手动安装并生成:
dockerfile# Dockerfile示例 FROM docker.xuanyuan.run/arm64v8/debian:latest RUN apt-get update && apt-get install -y locales && rm -rf /var/lib/apt/lists/* \ && localedef -i en_US -c -f UTF-8 -A /usr/share/locale/locale.alias en_US.UTF-8 ENV LANG en_US.utf8
Dockerfile示例:构建应用镜像
以构建一个包含Python的应用镜像为例:
dockerfileFROM docker.xuanyuan.run/arm64v8/debian:12-slim # 更新apt源并安装Python RUN apt-get update && apt-get install -y --no-install-recommends \ python3 \ python3-pip \ && rm -rf /var/lib/apt/lists/* # 设置工作目录 WORKDIR /app # 复制应用代码并安装依赖 COPY requirements.txt . RUN pip3 install --no-cache-dir -r requirements.txt COPY . . # 运行应用 CMD ["python3", "app.py"]
docker-compose配置示例
yamlversion: '3' services: app: build: . image: docker.xuanyuan.run/arm64v8/debian:12-slim container_name: my-debian-app environment: - LANG=C.UTF-8 volumes: - ./app:/app command: bash -c "cd /app && python3 app.py"
镜像变体
arm64v8/debian:<suite>-slim
slim变体通过移除非必要文件(如文档、man pages、 locales生成文件)进一步减小镜像体积,适合对镜像大小敏感的场景。其构建过程使用debuerreotype-slimify工具,具体移除内容可参考https://github.com/debuerreotype/debuerreotype。
使用建议:生产环境中优先选择slim变体,减少资源占用;开发环境可使用标准变体以保留完整工具链。
维护与支持
维护者
Debian开发者 https://qa.debian.org/developer.php?login=tianon 和 https://qa.debian.org/developer.php?login=paultag
获取帮助
- https://dockr.ly/comm-slack
- Server Fault
- https://unix.stackexchange.com/help/on-topic
- https://stackoverflow.com/help/on-topic
提交Issue
https://github.com/debuerreotype/docker-debian-artifacts/issues?q=
支持的架构
amd64, arm32v5, arm32v7, arm64v8, i386, `
镜像拉取方式
您可以使用以下命令拉取该镜像。请将 <标签> 替换为具体的标签版本。如需查看所有可用标签版本,请访问 标签列表页面。
DockerHub 原生拉取命令
用户好评
来自真实用户的反馈,见证轩辕镜像的优质服务