containers / containers/podman-compose

The entrypoint can't be unset via `--entrypoint=''`

Open Beginner friendly
#1,546 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Python
Stars
6.2k
Forks
622
PR merge metrics
No merged PRs in 30d

Description

The entrypoint can't be unset via `podman compose run --entrypoint=''`

**To Reproduce**
Create `compose.yaml` with the following content:
```yaml
services:
repro:
image: docker.io/library/busybox:1.38.0-uclibc
entrypoint: ["/bin/echo", "original entrypoint"]
```
Run
```
podman compose -f compose.yaml run --rm --entrypoint '' repro /bin/sh -c 'echo entrypoint-cleared'
```

**Expected behavior**
The output is `entrypoint-cleared`

**Actual behavior**
The output is `original entrypoint /bin/sh -c echo entrypoint-cleared`

**Output**

```
$ podman-compose version
podman-compose version 1.6.0
podman version 6.1.0
```

**Environment:**
- OS: Arch Linux (probably reproducible on any)
- podman version:
- podman compose version: 1.6.0-1 (Arch package; it doesn't show commit hash is was built from)

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the command with the provided compose.yaml and inspect the entrypoint handling for `podman compose run --entrypoint`. The fix is done when an empty `--entrypoint ''` clears the service entrypoint and the command prints `entrypoint-cleared`; verify the existing reproduction still works with Podman Compose 1.6.0.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.