Use docker-compose inside a snap

Hello everyone,

I’m trying to create a snap that deploys some Docker containers using “docker-compose,” but I’m encountering some issues… I’m attaching my snapcraft.yaml:

name: q-deployer
base: core22
version: '0.1' 
summary: q-deployer
description: |

grade: stable # must be 'stable' to release into candidate/stable channels
confinement: strict # use 'strict' once you have the right plugs and slots

    plugin: dump
    source: ./scripts
    plugin: nil
    stage-packages: [gettext-base]
    stage: [usr/bin/envsubst]

    plugin: nil
    source: .
    source-type: local
    override-build: |
      mkdir -p $SNAPCRAFT_PART_INSTALL/edl
      cp -R snap/local/images $SNAPCRAFT_PART_INSTALL/edl/
      cp -R snap/local/traefik_template $SNAPCRAFT_PART_INSTALL/edl/
      cp snap/local/docker-compose.yml $SNAPCRAFT_PART_INSTALL/edl/

    command: ./
    stop-command: ./
    restart-delay: 1m
    restart-condition: on-failure
    daemon: simple
    install-mode: disable
      - docker
      - docker-executables
      - network
      - network-setup-observe
      - network-observe

    interface: content
    target: $SNAP/docker-exes
    default-provider: docker:docker-executables

By using the docker-executables plug, I can see the Docker binaries of my machine. I can easily run commands based on “docker” (e.g., docker run, docker load, etc.), but when I try to run a command based on “docker-compose,” the following happens:

root@devbook:/snap/q-deployer/x1# docker-exes/bin/docker-compose 
Traceback (most recent call last):
  File "/snap/q-deployer/x1/docker-exes/bin/docker-compose", line 33, in <module>
    sys.exit(load_entry_point('docker-compose==1.29.2', 'console_scripts', 'docker-compose')())
  File "/snap/q-deployer/x1/docker-exes/bin/docker-compose", line 22, in importlib_load_entry_point
    for entry_point in distribution(dist_name).entry_points
  File "/usr/lib/python3.10/importlib/metadata/", line 969, in distribution
    return Distribution.from_name(distribution_name)
  File "/usr/lib/python3.10/importlib/metadata/", line 548, in from_name
    raise PackageNotFoundError(name)
importlib.metadata.PackageNotFoundError: No package metadata was found for docker-compose

I want to mention that I’m currently using this version of Docker:

docker 20.10.17 2750 core18/stable canonical✓ -

I’m aware that it’s a quite old version, but it’s the only one currently compatible with my target machine.

Can you help me understand what the issue might be? PLEASE!