Determine which directory a docker compose cmd was run in

I’m guessing there must be a way to see which directory a particular container resulted from… Say you have multiple docker-compose.ymls in various directories, and some are the same. Say you’d like to take that container down wtih docker-compose down container.

You can run

docker container inspect CONTAINERNAME

to get the labels. Docker Compose adds labels to show where the compose files are. If you run

docker compose ls

from anywhere, it will also show the known Docker Compose projects and project roots.

Thanks - it was in the container inspection under com.docker.compose.project.config_files!