Tutor with Podman not working


I am trying Tutor with Podman in a virtualenv under an unprivileged Linux account, like described in https://docs.tutor.overhang.io/podman.html, but it is failing to execute tutor local quickstart because podman-compose lacks some docker-compose commands like “rm” that tutor uses.

podman-compose has {help,version,pull,push,build,up,down,ps,run,start,stop,restart,logs}

This is the way I have tried so far:

# su - gbcm
$ mkdir ~/virtualenv
$ virtualenv ~/virtualenv/valdirverona_edx
$ cd ~/virtualenv/valdirverona_edx/bin
$ source activate
$ python --version
Python 3.6.8
$ pip3 install tutor-openedx
$ pip3 install podman-compose
$ ln -s $(which podman-compose) $(dirname $(which podman-compose))/docker-compose
$ pip3 list | egrep 'podman-compose|tutor'
podman-compose    0.1.7.dev0
tutor-openedx     10.2.1
$ tutor local quickstart
Configuration saved to /containers/home/gbcm/.local/share/tutor/config.yml
        Updating the current environment
Environment generated in /containers/home/gbcm/.local/share/tutor/env
        Stopping any existing platform
docker-compose -f /containers/home/gbcm/.local/share/tutor/env/local/docker-compose.yml -f /containers/home/gbcm/.local/share/tutor/env/local/docker-compose.prod.yml --project-name tutor_local rm --stop --force
usage: docker-compose [-h] [-f file] [-p PROJECT_NAME]
                      [--podman-path PODMAN_PATH] [--no-ansi] [--no-cleanup]
                      [-t {1pod,1podfw,hostnet,cntnet,publishall,identity}]
docker-compose: error: argument command: invalid choice: 'rm' (choose from 'help', 'version', 'pull', 'push', 'build', 'up', 'down', 'ps', 'run', 'start', 'stop', 'restart', 'logs')
Error: Command failed with status 2: docker-compose -f /containers/home/gbcm/.local/share/tutor/env/local/docker-compose.yml -f /containers/home/gbcm/.local/share/tutor/env/local/docker-compose.prod.yml --project-name tutor_local rm --stop --force

Am I missing something?

Thanks and Kind Regards,
Guilherme Monteiro

Thanks for the report @GuilhermeBCM! This will be fixed in the next release: https://github.com/overhangio/tutor/commit/e9585bdc80c41c284b044b102819b762cd8f64cb

1 Like

Thanks for the fix @regis.
I did upgrade tutor to 10.2.2 but the change to docker-compose stop requires service as argument, as seen below:

docker-compose -f /containers/home/gbcm/.local/share/tutor/env/local/docker-compose.yml -f /containers/home/gbcm/.local/share/tutor/env/local/docker-compose.prod.yml --project-name tutor_local stop
usage: docker-compose stop [-h] [-t TIMEOUT] services [services …]
docker-compose stop: error: the following arguments are required: services
Error: Command failed with status 2: docker-compose -f /containers/home/gbcm/.local/share/tutor/env/local/docker-compose.yml -f /containers/home/gbcm/.local/share/tutor/env/local/docker-compose.prod.yml --project-name tutor_local stop

I have just upgraded every outdated pip package and tried again tutor local quickstart. Please let me know if I need to try anything else.

Thanks and Kind Regards,

This is very annoying. How is one supposed to stop an entire platform with podman-compose?

I see that there is a related open issue in the podman-compose project: https://github.com/containers/podman-compose/issues/110

I’ll ask if the podman-compose project is open to a PR on this.

After reading several blog posts on this topic, I now realize that podman-compose is not a production-ready replacement for docker-compose, yet:


It seems to me that attempting to replace all docker-compose commands by a new tool is a hopeless quest. Instead, we should be using docker-compose and emulate the docker API by creating a custom docker.sock.

I guess we should probably add a big fat warning to the podman documentation on the Tutor docs. @fghaas as the main author of the Podman integration docs, what are your thoughts on this?

My thoughts are that I didn’t run into any issues with podman-compose at the time I wrote the patch that added that note in the docs — but it’s obviously entirely possible that that bit is now outdated, since I haven’t been using Tutor all that much in the interim. So yes if that information is no longer current, we can definitely add a warning saying that using Tutor with Podman, or specifically with podman-compose is experimental and YMMV.

Here’s some proposed wording:

Let me know what you think!

Opinion of a very new tutor user (me):
After a frustrating first experience on tutor because of this podman-compose issues, and now a very positive experience running it on docker, my suggestion is to change podman support on tutor to “work in progress”, hide this instructions within the issue, leave it on roadmap and blocked because of lacking features of podman-compose, and when possible work again on this, if desired.

Kind Regards,

@regis — your call. If you want stronger wording on the PR, let me know. Or else, you can just revert this commit:

Backing that one out should remove all mentions of Podman from the documentation.

If you want stronger wording on the PR, let me know.

Yes @fghaas, I’m torn. I would really really like for Tutor to be compatible with Podman, but it’s frustrating that podman-compose is not a drop-in replacement with docker-compose. I’ll merge your PR and add some extra comments to suggest a different solution.

That works for me, thanks!

:thinking: Using Podman and Docker Compose

Looks like docker-compose is now officially supported in Podman! Does someone want to try it out with Tutor on Ubuntu 20.10?