containers / podman-compose

a script to run docker-compose.yml using podman
GNU General Public License v2.0
4.85k stars 463 forks source link

Wrongly relative path by include #947

Open HernandoR opened 1 month ago

HernandoR commented 1 month ago

Describe the bug By the docker compose spec, each included files should be treated as individual project. Meaning that

  1. Relative path in the docker compose file should be considered as relative to the corresponding project directory.
  2. Each included file may have a corresponding .env file, which should be override by the parent file. To Reproduce

suggesting a structure as

./include/
├── docker-compose.yaml
├── extend
│   └── docker-compose.extend.yaml
└── extend2
    └── docker-compose.extend2.yaml

where as each extended docker-compose try to map ./config, Calling docker compose at include

Expected behavior

service in extend map extend/config; extend2 map extend2/config

Actual behavior

all service mapping include/config

Output

$ podman-compose version
podman-compose version 1.0.7
podman version 4.3.1
podman --version 
podman version 4.3.1

Additional context

It is not a run time problem, but an designing inconsistance.

HernandoR commented 1 month ago

Related document Compose spec docker-compose/include