cli icon indicating copy to clipboard operation
cli copied to clipboard

docker-compose do not use --project-name param to set COMPOSE_PROJECT_NAME

Open arvabalazs opened this issue 2 years ago • 3 comments

This is an issue in docker-compose but affects devcontainers: the devcontainer use docker-compose --project-name <project-name>, but unfortunatelly and surprisingly it do not set COMPOSE_PROJECT_NAME for the compose file. The short version of that command line param behave correctly (-p). I would recommend to change --project-name command line param usage to -p.

arvabalazs avatar Sep 17 '23 17:09 arvabalazs

Hi 👋

Thanks for suggestion, I like the idea of adding support for --project-name . As this 💡 is more aligned with the @devcontainers/cli, @arvabalazs any concerns with transferring this issue to the cli repo?

samruddhikhandale avatar Sep 18 '23 21:09 samruddhikhandale

Hi

I am not sure we are thinking about the same thing. Sorry, probably I am not defined what is the issue here:

  1. docker-compose has a bug with '--project-name' command line param: its behavior is different than '-p' param, because it do not set COMPOSE_PROJECT_NAME variable
  2. devcontainers vscode extension uses '--project-name' already

Maybe my bug report in the wrong project. Can somebody help me, where it should be?

arvabalazs avatar Sep 19 '23 07:09 arvabalazs

I see, thanks for correcting my understanding. Transferred it to the cli repo.

samruddhikhandale avatar Sep 19 '23 16:09 samruddhikhandale