3 ms·
> Podman has added full docker-compose support any pointers as to how this works?
by jackhalford 5y ago
> Podman has added full docker-compose support
any pointers as to how this works?
- rubenbe 5y agoIIRC it's emulating the docker socket and its API. As a consequence, you do need to have a podman daemon running. https://fedoramagazine.org/use-docker-compose-with-podman-to-orchestrate-containers-on-fedora/ https://fedoramagazine.org/use-docker-compose-with-podman-to... https://www.redhat.com/sysadmin/podman-docker-compose https://www.redhat.com/sysadmin/podman-docker-compose
- gizdan 5y agoAs rubenbe said, they implemented the docker API, thus you'll need to start a systemd socket. For rootless the steps are as simple as systemctl enable --now --user podman.socket export DOCKER_HOST=unix://$XDG_RUNTIME_DIR/podman/podman.sock For rootfull just remove "--user" from the above command, and the socket is located at /var/podman/podman.sock Then you can run both docker and docker-compose commands. Traefik and other things that use the Docker API directly should be able to use it too. Any issues you can raise on the GitHub repo, they're a bunch of friendly folks and are pretty quick at addressing issues.
- aorth 5y agoSo, as long as you have the podman socket enabled, you can just run the literal docker-compose script with `podman` aliased to `docker`? Interesting and cool! I think I still prefer not having to enable the socket and export DOCKER_HOST, but I will think about it. The only problems I had with podman-compose in the past few months were related to syntax issues in the docker-compose.yml file (for example ports, image names without prefixes, etc).
- gizdan 5y agoNo, the podman socket is only necessary if you want to expose the docker API. This can then be used with the docker cli (or docker-compose). The podman cli interface is close to the docker cli interface, which is why you can do `alias docker=podman`. With the socket you would be using the official docker cli (or docker-compose), not the podman cli.