compose/pkg
Milas Bowman 61845dd781
logs: filter to services from current Compose file (#9811)
* logs: filter to services from current Compose file

When using the file model, only attach to services
referenced in the active Compose file.

For example, let's say you have `compose-base.yaml`
and `compose.yaml`, where the former only has a
subset of the services but are both run as part of
the same named project.

Project based command:
```
docker compose -p myproj logs
```
This should return logs for active services based
on the project name, regardless of Compose file
state on disk.

File based command:
```
docker compose --file compose-base.yaml logs
```
This should return logs for ONLY services that are
defined in `compose-base.yaml`. Any other services
are considered 'orphaned' within the context of the
command and should be ignored.

See also #9705.

Fixes #9801.

Signed-off-by: Milas Bowman <milas.bowman@docker.com>
2022-09-08 16:26:00 -04:00
..
api logs: filter to services from current Compose file (#9811) 2022-09-08 16:26:00 -04:00
compose logs: filter to services from current Compose file (#9811) 2022-09-08 16:26:00 -04:00
e2e convert: do not escape $ into $$ when using the --no-interpolate option (#9703) 2022-09-08 16:25:23 -04:00
mocks mocks: create mocks for compose api.Service 2022-06-07 17:09:06 -05:00
progress lint: add `nolintlint` and clean up `nolint` directives (#9738) 2022-08-09 16:43:58 -04:00
prompt move compose-cli code into docker/compose/v2 2021-08-31 19:09:19 +02:00
utils don't push images at the end of multi-arch build (and simplify e2e tests) 2022-09-02 15:44:55 +02:00