> For the complete documentation index, see [llms.txt](https://camelgemonion.gitbook.io/docker/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://camelgemonion.gitbook.io/docker/dockerfile-zhi-ling/parser-directives/syntax.md).

# syntax

```
# syntax=[remote image reference]
```

示例：

```
# syntax=docker/dockerfile
# syntax=docker/dockerfile:1.0
# syntax=docker.io/docker/dockerfile:1
# syntax=docker/dockerfile:1.0.0-experimental
# syntax=example.com/user/repo:tag@sha256:abcdef...
```

**仅当使用BuildKit后端时才启用此功能。**

**syntax指令**定义用于构建当前**Dockerfile**的**Dockerfile构建器**的位置。 **BuildKit**后端允许无缝使用构建器的外部实现，这些构建器以**Docker**镜像的形式分发并在容器沙箱环境中执行。

自定义**Dockerfile构建器**的实现将允许我们执行以下操作：

* 自动获取错误修&#x6B63;**(bugfixs)**，而无需更新守护进程
* 确保所有用户都使用相同的实现来构建**Dockerfile**
* 使用最新功能，而无需更新守护程序
* 试用新的实验性或第三方功能


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://camelgemonion.gitbook.io/docker/dockerfile-zhi-ling/parser-directives/syntax.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
