Docker 驱动程序

Buildx Docker 驱动程序是默认驱动程序。它使用直接内置于 Docker 引擎中的 BuildKit 服务器组件。 Docker 驱动程序不需要配置。

与其他驱动程序不同,使用 Docker 驱动程序的构建器无法手动创建。它们仅从 Docker 上下文自动创建。

使用 Docker 驱动程序构建的镜像会自动加载到本地镜像存储中。

概要

# The Docker driver is used by buildx by default
docker buildx build .

无法配置要使用的 BuildKit 版本,也无法使用 Docker 驱动程序将任何其他 BuildKit 参数传递给构建器。 BuildKit版本和参数是Docker引擎内部预设的。

如果您需要额外的配置和灵活性,请考虑使用 Docker 容器驱动程序

进一步阅读

有关 Docker 驱动程序的更多信息,请参阅 buildx 参考