containers / containers/podman-compose
Podman Compose fails to recognise host-gateway
- Dominant language
- Python
- Stars
- 6.2k
- Forks
- 622
- PR merge metrics
- No merged PRs in 30d
Description
**Describe the bug**
I am running podman and podman console on windows 10 machine. I have used my previous docker compose yaml file to run containers using podman compose. However the containers fail to run due to the following error.
`Error: invalid IP address in add-host: "host-gateway"`
**To Reproduce**
Steps to reproduce the behavior:
1. Podman-compose up
please use [minimal reproducible example](https://stackoverflow.com/help/minimal-reproducible-example) for example give me a small busybox-based compose yaml
```
version: "3.9"
services:
configurationsService:
image: "localhost/configurations-service"
hostname: configurationsService
ports:
- "51000:51000"
healthcheck:
test: "curl --fail --silent configurationsService:51000/actuator/health | grep UP || exit 1"
interval: 20s
timeout: 5s
retries: 5
start_period: 40s
restart: always
inventoryInfo:
image: "localhost/inventory-service"
hostname: inventoryService
ports:
- "51005:51005"
depends_on:
configurationsService:
condition: service_healthy
extra_hosts:
- "host.docker.internal:host-gateway"
restart: always
```
**Expected behavior**
Containers should start successfully
**Actual behavior**
Error: invalid IP address in add-host: "host-gateway
**Output**
```
$ podman-compose version
using podman version: 3.4.0
podman-compose version 0.1.7dev
podman --version
podman version 3.4.0
$ podman-compose up
...
```
**Environment:**
- OS: WSL
- podman version:
```
Client: Podman Engine
Version: 4.5.0
API Version: 4.5.0
Go Version: go1.19.7
Built: Fri Apr 14 21:12:56 2023
OS/Arch: linux/amd64
```
- podman compose version: (git hex)
```
podman-compose version: 1.0.6
['podman', '--version', '']
using podman version: 4.5.0
podman-compose version 1.0.6
podman --version
podman version 4.5.0
```
Contributor guide
Assessment
This issue has not been assessed yet.