A compose file with variable substitution, an override and an anchor is not readable by inspection, and the gap between what you think it says and what it says is where the afternoon goes.
$ docker-compose config --services
$ docker-compose config -q && echo valid
$ docker-compose -f docker-compose.yml -f docker-compose.ci.yml config
> /tmp/resolved.yml
$ diff /tmp/resolved.yml /tmp/resolved-previous.yml
Running it with -q in CI turns a malformed file into a build failure rather than a deploy failure, and it costs nothing. The output has every variable substituted, which means it will happily print secrets — worth remembering before pasting it into a ticket. Diffing the resolved output between two branches is the fastest way to review a compose change that touches an override, because the override’s effect is otherwise invisible.