Conflicts when trying to install `docker-compose` having `podman` and `podman-docker` already installed

On Fedora 40 I believe I had installed all three packages: podman, podman-docker and docker-compose. After upgrading to Fedora 41 with the option --allowerasing due to conflicts among packages I think docker-compose was removed. Now, when I try to install it back I’m getting conflicts. How can I fix it?

[piotr@fedora]~% dnf5 list --installed '*podman*'
Installed packages
podman.x86_64        5:5.2.3-1.fc41 <unknown>
podman-docker.noarch 5:5.2.3-1.fc41 updates-testing

[piotr@fedora]~% dnf5 list --installed '*docker*'
Installed packages
podman-docker.noarch          5:5.2.3-1.fc41 updates-testing
python3-docker.noarch         7.1.0-3.fc41   <unknown>
python3-docker+ssh.noarch     7.1.0-3.fc41   <unknown>
python3-docker-pycreds.noarch 0.4.0-21.fc41  <unknown>
python3-dockerpty.noarch      0.4.1-33.fc41  <unknown>

[piotr@fedora]~% sudo dnf5 install docker-compose
Updating and loading repositories:
Repositories loaded.
Failed to resolve the transaction:
Problem: conflicting requests
  - package docker-compose-2.29.7-1.fc41.x86_64 from updates-testing requires docker-cli, but none of the providers can be installed
  - package docker-compose-2.29.2-1.fc41.x86_64 from fedora requires docker-cli, but none of the providers can be installed
  - problem with installed package
  - installed package podman-docker-5:5.2.3-1.fc41.noarch conflicts with podman-docker provided by docker-cli-27.2.0-1.fc41.x86_64 from fedora
  - package docker-cli-27.2.0-1.fc41.x86_64 from fedora conflicts with podman-docker provided by podman-docker-5:5.2.3-1.fc41.noarch from updates-testing
  - package docker-cli-27.2.0-1.fc41.x86_64 from fedora conflicts with podman-docker provided by podman-docker-5:5.2.3-1.fc41.noarch from fedora
  - installed package podman-docker-5:5.2.3-1.fc41.noarch conflicts with podman-docker provided by docker-cli-27.3.1-1.fc41.x86_64 from updates-testing
  - package docker-cli-27.3.1-1.fc41.x86_64 from updates-testing conflicts with podman-docker provided by podman-docker-5:5.2.3-1.fc41.noarch from updates-testing
  - package docker-cli-27.3.1-1.fc41.x86_64 from updates-testing conflicts with podman-docker provided by podman-docker-5:5.2.3-1.fc41.noarch from fedora
You can try to add to command line:
  --allowerasing to allow erasing of installed packages to resolve problems
  --skip-broken to skip uninstallable packages

It looks like it is showing some conflicts coming from the updates-testing repo. I’d try disabling the updates-testing repo and then see if you can install the package.

1 Like

Isn’t unreleased version of Fedora (41 here) supposed to use updates-testing the same way released version uses updates?

Yes, except that in the case of a released version, a package isn’t released to the updates repo until after it has passed some basic testing via the updates-testing repo. That is, for a normal release, the path would be updates-testingupdatessystem. For the beta release, the end users are exposed to the updates-testing repo directly (and that can result in your seeing issues like this one that would normally be “caught” before they hit an end user).

2 Likes

Still the same:

[piotr@fedora]~% sudo dnf5 install --disablerepo=updates-testing docker-compose 
Updating and loading repositories:
Repositories loaded.
Failed to resolve the transaction:
Problem: problem with installed package
  - installed package podman-docker-5:5.2.3-1.fc41.noarch conflicts with podman-docker provided by docker-cli-27.2.0-1.fc41.x86_64 from fedora
  - package docker-cli-27.2.0-1.fc41.x86_64 from fedora conflicts with podman-docker provided by podman-docker-5:5.2.3-1.fc41.noarch from fedora
  - package docker-compose-2.29.2-1.fc41.x86_64 from fedora requires docker-cli, but none of the providers can be installed
  - conflicting requests
You can try to add to command line:
  --allowerasing to allow erasing of installed packages to resolve problems
  --skip-broken to skip uninstallable packages

Have you tried passing --refresh to your dnf install command? Otherwise, if there is a conflict between two packages in the fedora repo, that is a bigger problem and it probably warrants a bug report.

No change with --referesh:

[piotr@fedora]~% sudo dnf5 install --disablerepo=updates-testing --refresh docker-compose
Updating and loading repositories:
 Fedora 41 - x86_64                                                                                                                                                       100% |  46.7 KiB/s |  23.6 KiB |  00m01s
 Copr repo for scrcpy owned by zeno                                                                                                                                       100% |   4.4 KiB/s |   1.8 KiB |  00m00s
 google-chrome                                                                                                                                                            100% |  12.4 KiB/s |   1.3 KiB |  00m00s
 Fedora 41 - x86_64 - Updates                                                                                                                                             100% |  56.9 KiB/s |  27.2 KiB |  00m00s
 Fedora 41 openh264 (From Cisco) - x86_64                                                                                                                                 100% |   2.6 KiB/s | 989.0   B |  00m00s
Repositories loaded.
Failed to resolve the transaction:
Problem: problem with installed package
  - installed package podman-docker-5:5.2.3-1.fc41.noarch conflicts with podman-docker provided by docker-cli-27.2.0-1.fc41.x86_64 from fedora
  - package docker-cli-27.2.0-1.fc41.x86_64 from fedora conflicts with podman-docker provided by podman-docker-5:5.2.3-1.fc41.noarch from fedora
  - package docker-compose-2.29.2-1.fc41.x86_64 from fedora requires docker-cli, but none of the providers can be installed
  - conflicting requests
You can try to add to command line:
  --allowerasing to allow erasing of installed packages to resolve problems
  --skip-broken to skip uninstallable packages

It doesn’t look like there was a docker-cli package in Fedora 40. Are you sure you need it? Otherwise, the docker-cli and podman-docker packages appear to be mutually exclusive.

I think you’ve found a packaging bug. It was possible to install both docker-compose and podman-docker at the same time on Fedora Linux 40.

# rpm -q docker-compose podman-docker
docker-compose-1.29.2-12.fc40.noarch
podman-docker-5.2.2-1.fc40.noarch

I don’t need docker-cli and as shown in my original post it’s not installed. It seems that it’s required by docker-compose which I want to install and at the same time it conflicts with already installed podman-docker.
I think what’s wrong is the fact that docker-compose requires docker-cli because two other packages podman and podman-docker should supply all things needed by docker-compose.
Where should I raise this?

I think you’ve found a packaging bug that should be reported.

In the meanwhile, as a workaround, since there are no other package dependencies, you could probably get away with forcing the install to ignore the dependency by first downloading the docker-compose package with dnf download docker-compose, then installing it with rpm --nodeps -ivh docker-compose-*.rpm.

https://bugzilla.redhat.com/

File a bug report against the docker-compose package in Fedora Linux 41.

Edit: You might also need to add something like ignore=docker* to /etc/dnf/dnf.conf so future updates will proceed and ignore the docker package conflicts (I’m not sure if that will work with dnf5).

2 Likes

If I’m reading this right, it looks like there is a new docker-compose-switch package (docker-compose-switch-1.0.5-1.fc41 | Build Info | koji) that is supposed to replace the docker-compose package. Maybe that is what needs to be installed instead of docker-compose?

Edit: Chasing some links, it looks like there is some discussion about these new packages and new dependencies here: The Docker Stack and Go Vendoring - golang - Fedora mailing-lists

Maybe that is what needs to be installed instead of docker-compose?

Reading the description

Compose Switch is a replacement for the Compose V1 “docker-compose” (python)
executable. It translates the command line into Compose V2 “docker compose” and
then runs the latter.

I think this is something different. It looks like it’s for apps/tools using V1 version api of docker-compose so that they would continue to work with V2 version api which I believe is provided both by docker-compose and podman-compose.

As to https://bugzilla.redhat.com/ 1, Fedora has only 39887 components to choose from and the whole page freezes my system… Which component should I choose when reporting packaging conflicts?

As to The Docker Stack and Go Vendoring - golang - Fedora mailing-lists it looks like something already done (docker-cli (split out from moby-engine)) and not the reason for this problem.

Actually, it looks like there has already been a lot of turmoil with regard to this package that is being iterated over in this bugzilla report: 2000794 – docker-compose-2.14.0 is available

You might just tac a comment onto the end of that report noting that Fedora Linux 41 users are hitting these issues.

Just did.
Thank you very much for all your help with this!

I thought that maybe downgrading podman and podman-docker to versions available in updates would help but it seems updates and updates-testing have the same versions:

[piotr@fedora]~% sudo dnf5 reinstall --disablerepo=updates-testing --refresh podman podman-docker               
Updating and loading repositories:
 Fedora 41 - x86_64                                                                                                                                                       100% | 256.4 KiB/s |  23.6 KiB |  00m00s
 Copr repo for scrcpy owned by zeno                                                                                                                                       100% |   4.1 KiB/s |   1.8 KiB |  00m00s
 google-chrome                                                                                                                                                            100% |  11.8 KiB/s |   1.3 KiB |  00m00s
 Fedora 41 - x86_64 - Updates                                                                                                                                             100% | 288.9 KiB/s |  27.2 KiB |  00m00s
 Fedora 41 openh264 (From Cisco) - x86_64                                                                                                                                 100% |  13.4 KiB/s | 989.0   B |  00m00s
Repositories loaded.
Package                                                                 Arch            Version                                                                 Repository                                    Size
Reinstalling:
 podman                                                                 x86_64          5:5.2.3-1.fc41                                                          fedora                                    48.0 MiB
   replacing podman                                                     x86_64          5:5.2.3-1.fc41                                                          <unknown>                                 48.0 MiB
 podman-docker                                                          noarch          5:5.2.3-1.fc41                                                          fedora                                    10.9 KiB
   replacing podman-docker                                              noarch          5:5.2.3-1.fc41                                                          updates-testing                           10.9 KiB

Transaction Summary:
 Reinstalling:       2 packages
 Replacing:          2 package

Total size of inbound packages is 15 MiB. Need to download 15 MiB.
After this operation, 0 B extra will be used (install 48 MiB, remove 48 MiB).
Is this ok [y/N]:
1 Like

Downgrading might be another option if you add --releasever=40 to downgrade to the Fedora Linux 40 versions of the packages. That will probably work, but it won’t be a supported/tested configuration. If it does work, add an exclude=... line to /etc/dnf/dnf.conf to prevent dnf from updating the packages back to the Fedora Linux 41 versions. If it doesn’t work, just run dnf update again to switch back to the newer packages.

Edit: Don’t do the downgrade if it tries to also downgrade a bunch of “system” packages like python-whatever. Only proceed if it will only downgrade a small handful of packages to the versions from the previous release.

Edit2: Any time you are “forcing” package installs or otherwise doing strange and unusual/untested things, you should consider making a snapshot of your root filesystem so you can be more certain that you will be able to recover (without having to completely reinstall) if it doesn’t work: Make use of Btrfs snapshots to upgrade Fedora Linux with easy fallback - Fedora Magazine

Edit3: In your case, you might be able to just run dnf install --releasever=40 docker-compose without downgrading anything.

The docker related packages (moby, docker-buildx, docker-compose, and docker-compose-switch) were completely revised for F41 and newer versions of Fedora. docker-compose does indeed have a Requires docker-cli listed which may be a change from earlier versions.

Another option is to try podman-compose which aims to provide the features of docker-compose in the podman ecosystem. There is also quadlets available with podman,

Is docker-compose a requirement to install with podman-docker ? If so I can check with the package maintainers.

1 Like

If this prevents installation of docker-compose in addition to podman and podman-docker that would be very unfortunate.

I tried it and found out it does not support --profiles option which is being used by PyCharm – docker compose config – --profiles option not supported · Issue #1052 · containers/podman-compose · GitHub

Not sure I understand the direction of requirements in this question.
I think the idea is that docker the command can be provided by the original Docker code (distributed now in docker-cli package?) or by the RedHat’s Podman distributed in podman package together with podman-docker package which provides symlink dockerpodman. On top of this we have docker-compose the command[1] which again can be provided by the original Docker code distributed in docker-compose package or by RedHat’s implementation which is distributed in podman-compose.
In other words the original docker-compose implementation from Docker (distributed in package with the same name) should be able to work on top of either the original docker implementation from Docker (distributed in package docker-cli?) or RedHat’s alternative implementation of docker (distributed in package podman together with package podman-docker).

[piotr@fedora]~% sudo dnf5 install --releasever=40 docker-compose
Updating and loading repositories:
Repositories loaded.
Failed to resolve the transaction:
Problem: python3-3.12.2-2.fc40.i686 from fedora has inferior architecture
  - package docker-compose-1.29.2-12.fc40.noarch from fedora requires python(abi) = 3.12, but none of the providers can be installed
  - python3-3.12.6-1.fc40.i686 from updates has inferior architecture
  - python3-3.12.7-1.fc40.i686 from updates-testing has inferior architecture
  - cannot install both python3-3.12.2-2.fc40.x86_64 from fedora and python3-3.13.0~rc3-1.fc41.x86_64 from @System
  - cannot install both python3-3.12.6-1.fc40.x86_64 from updates and python3-3.13.0~rc3-1.fc41.x86_64 from @System
  - cannot install both python3-3.12.7-1.fc40.x86_64 from updates-testing and python3-3.13.0~rc3-1.fc41.x86_64 from @System
  - installed package python3-google-re2-1:20240702-19.fc41.x86_64 requires python(abi) = 3.13, but none of the providers can be installed
  - conflicting requests
  - problem with installed package
You can try to add to command line:
  --skip-broken to skip uninstallable packages

Adding --skip-broken doesn’t change anything.

This works as a workaround, thanks!

I opened discussion about this in podman’s github repo – Conflicts when trying to install `docker-compose` having `podman` and `podman-docker` already installed on Fedora 41 · containers/podman · Discussion #24143 · GitHub


  1. Actually it’s not command per se but a plugin to docker the command which is invoked when one runs docker compose. It’s provided by the package docker-compose in the form of /usr/libexec/docker/cli-plugins/docker-compose ↩︎

I wonder if it really calls that command if you have the podman-docker package installed?

$ which docker
/usr/bin/docker
$ rpm -qf /usr/bin/docker
podman-docker-5.2.2-1.fc40.noarch
$ file /usr/bin/docker
/usr/bin/docker: a /usr/bin/sh script, ASCII text executable
$ cat /usr/bin/docker
#!/usr/bin/sh
[ -e /etc/containers/nodocker ] || \
echo "Emulate Docker CLI using podman. Create /etc/containers/nodocker to quiet msg." >&2
exec /usr/bin/podman "$@"

If I’m reading that right, docker compose ends up getting translated to podman compose.

Yes, you are right. But what happens next is that podman seeing compose verb looks for a plugin which implements it the same way docker does when it sees compose verb. Subsequently either docker-compose is being invoked (the original Docker implementation of compose) or podman-compose is being invoked (RedHat’s implementation of compose).

1 Like

I created an issue asking for a change that enables support for podman-docker as a provider for docker cli.

https://bugzilla.redhat.com/show_bug.cgi?id=2316333

2 Likes