Confusing and contradictory information about paths resolving in extend

未关闭 适合新手
#26,501 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

@Duo-ee 已经在做这个了。

开始于 2026年10月31日。

  • #26506 来自 @Duo-ee —— 未关闭

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
72/100
Issue 类型
文档
描述清晰度
基本清楚
活跃度
活跃
技术栈
docker-compose
领域
documentation

调研方向

阅读链接的 Docker Compose extends 页面中的“Important”区块和“Relative paths”部分,然后确认哪种行为是正确的。更新相互矛盾的说明,使页面始终一致地解释使用 extends 时路径如何解析。完成标准是,读者能够判断哪些路径相对于基础 Compose 文件,以及扩展服务中的路径如何处理。

由索引模型根据 Issue 内容生成。

描述

status/triage
Is this a docs issue?
  • My issue is about the documentation content or website
Type of issue

Information is incorrect

Description

The information in the important block contradicts with what is described in the "Relative paths" section.

"Important" block says:

When you use multiple Compose files, you must make sure all paths in the files are relative to the base Compose file (i.e. the Compose file in your main-project folder). (...)

And the "Relative paths" section describes the behavior as follows:

When using extends with a file attribute which points to another folder, relative paths declared by the service being extended are converted so they still point to the same file when used by the extending service.

This is confusing and is not obvious which information is true.

Location

https://docs.docker.com/compose/how-tos/multiple-compose-files/extends/

Suggestion

Remove either the "important" block or "relative paths" section - leave only the proper information.

主要语言
Markdown
星标
4.7k
派生
8.5k
平均合并
2 天 9 小时
30 天内合并 PR
126

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

docker/docs 的其他 Issue

查看 docker/docs 的全部 Issue

相似的 Issue

更多 Documentation Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。