podman-compose not working on macos
First a disclaimer - I'm new to podman & podman-compose so my issue could certainly be user error. I'll also mention I'm running this on macos 11.5.2.
I'm trying to podman-compose up what I feel like to be a pretty simple docker compose file (docker compose up works just fine). This file stands up a Kafka broker with an associated Zookeeper instance.
I installed podman via Homebrew and did podman machine init and podman machine start.
When I podman-compose up I get this:
podman pod create --name=chapter-5-quarkus-kafka-streams --share net -p 9092:9092 -p 2181:2181
b68778659dfa6d56fe81653bda74bbfaf22dc63e7188728eea7b77f6a90e4805
0
podman create --name=chapter-5-quarkus-kafka-streams_zookeeper_1 --pod=chapter-5-quarkus-kafka-streams -l io.podman.compose.config-hash=123 -l io.podman.compose.project=chapter-5-quarkus-kafka-streams -l io.podman.compose.version=0.0.1 -l com.docker.compose.container-number=1 -l com.docker.compose.service=zookeeper -e LOG_DIR=/tmp/logs --add-host zookeeper:127.0.0.1 --add-host chapter-5-quarkus-kafka-streams_zookeeper_1:127.0.0.1 --add-host kafka:127.0.0.1 --add-host chapter-5-quarkus-kafka-streams_kafka_1:127.0.0.1 strimzi/kafka:0.20.1-kafka-2.6.0 sh -c bin/zookeeper-server-start.sh config/zookeeper.properties
Error: short-name resolution enforced but cannot prompt without a TTY
125
podman create --name=chapter-5-quarkus-kafka-streams_kafka_1 --pod=chapter-5-quarkus-kafka-streams -l io.podman.compose.config-hash=123 -l io.podman.compose.project=chapter-5-quarkus-kafka-streams -l io.podman.compose.version=0.0.1 -l com.docker.compose.container-number=1 -l com.docker.compose.service=kafka -e LOG_DIR=/tmp/logs -e KAFKA_ADVERTISED_LISTENERS=PLAINTEXT://localhost:9092 -e KAFKA_LISTENERS=PLAINTEXT://0.0.0.0:9092 -e KAFKA_ZOOKEEPER_CONNECT=zookeeper:2181 --add-host zookeeper:127.0.0.1 --add-host chapter-5-quarkus-kafka-streams_zookeeper_1:127.0.0.1 --add-host kafka:127.0.0.1 --add-host chapter-5-quarkus-kafka-streams_kafka_1:127.0.0.1 strimzi/kafka:0.20.1-kafka-2.6.0 sh -c bin/kafka-server-start.sh config/server.properties --override listeners=$ --override advertised.listeners=$ --override zookeeper.connect=$
Error: short-name resolution enforced but cannot prompt without a TTY
125
podman start -a chapter-5-quarkus-kafka-streams_zookeeper_1
Error: no container with name or ID "chapter-5-quarkus-kafka-streams_zookeeper_1" found: no such container
125
podman start -a chapter-5-quarkus-kafka-streams_kafka_1
Error: no container with name or ID "chapter-5-quarkus-kafka-streams_kafka_1" found: no such container
125
Version Info
$ podman version
Client:
Version: 3.3.1
API Version: 3.3.1
Go Version: go1.17
Built: Mon Aug 30 15:15:26 2021
OS/Arch: darwin/amd64
Server:
Version: 3.3.0
API Version: 3.3.0
Go Version: go1.16.6
Built: Fri Aug 20 15:36:14 2021
OS/Arch: linux/amd64
I'm not sure of the podman-compose version (there isn't a version/--version command/flag), but I installed it today via pip3 install podman-compose
$ pip3 --version
pip 21.2.4 from /usr/local/lib/python3.9/site-packages/pip (python 3.9)
I found this article that explains this issue, tldr you need to add docker.io prefix before your containers https://marcusnoble.co.uk/2021-09-01-migrating-from-docker-to-podman/
@kevindurb Thanks for that article!
On another ticket (containers/podman#11397) I went through some back and forth, adding the unqualified-search-registries to my vm's registries.conf:
unqualified-search-registries=["docker.io", "quay.io", "registry.fedoreproject.org", "registry.access.redhat.com", "registry.redhat.io"]
short-name-mode="permissive"
That seems to work!
@kevindurb Thank you, that article of @AverageMarcus is so high quality, clears up so many things.