Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello fellow documentation writers 👋
I didn't understand this when reading it. The info box firstly has info about how
extends
got added and later removed and how it's not supported in 3.x. Then a message that it's included in1.27
and higher.Is it possible that someone with good insights into this rewrites this box with a clear indication of which version range of Docker Compose that supports
extends
and which doesn't?In 2021, @BretFisher wrote this nice summary:
moby/moby#31101 (comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@benjaoming Thanks for the feedback. Agree that the note needs to clarify support for
extends
. Created an internal ticket to get this updated. Thank you.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks so much @usha-mandya ! It was the second time that I ran into the
extends
support issue. I wasn't able to correctly recall my experience about 4 months ago, so had to read through all the many comments one more time.I think one of the important additions is also this one about how
depends_on
isn't possible in combination withextends
.Good luck and thanks, I will definitely need this part of the documentation again in a near future 💯
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@usha-mandya, IIUC - the extend should work on docker-compose version 1.27 and higher, and it's not related to the compose file format version? also, I saw here moby/moby#31101 (comment) that there is a recommendation to remove the version number at the beginning of the compose files, is it true?