Skip to content

podman-compose up error message suggests to use --replace option which is misleading - it does not exist #1118

@Fak3

Description

@Fak3

Describe the bug

podman-compose up gives misleading error message:

Error: creating container storage: the container name "podtest_myservice_1" is already in use by 
86c42c65343b40e1ee7798daf3e7493d9fd2c6fcb08467b8730d008c3f88b920. You have to remove 
that container to be able to reuse that name: that name is already in use, 
or use --replace to instruct Podman to do so.

But the there is no --replace option for docker-compose

To Reproduce

  1. mkdir mydir
  2. create minimal docker-compose.yml:
    services:
      myservice:
        image: alpine
        volumes:
          - ./mydir:/mydir:U
        command: touch /mydir/myfile
    
  3. run podman-compose up
  4. run podman-compose up again

Expected behavior

I expected to get a suggested option to force-replace container with docker-compose.

Actual behavior

Message says to use --replace option which does not exist for docker-compose

Output

> podman-compose version
podman-compose version 1.3.0
podman version 5.3.1

Environment:

  • OS: opensuse tumbleweed

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions