openshift / openshift/oadp-operator
Makefile container tool check only verifies binary exists, not runtime readiness
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 92
- Forks
- 93
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 43
Description
Problem
The Makefile's container tool availability check uses command -v which only verifies the binary exists on PATH:
ifeq ($(shell command -v $(CONTAINER_TOOL) >/dev/null 2>&1 && echo found),)
$(error The selected container tool '$(CONTAINER_TOOL)' is not available on this system.)
endif
On macOS with Podman, the podman binary is always present even when the Podman machine is stopped. This means the check passes, the Makefile proceeds with targets like deploy-olm (which first runs undeploy-olm), and only fails later when podman build is actually invoked. By that point, the existing deployment may already be torn down.
Expected behavior
The Makefile should detect that the container runtime is not functional before executing any destructive operations (like undeploy-olm). A check like podman info or docker info would verify the daemon/machine is actually running.
Suggested fix
Replace the command -v check with a runtime health check:
ifeq ($(shell $(CONTAINER_TOOL) info >/dev/null 2>&1 && echo found),)
$(error The container tool '$(CONTAINER_TOOL)' is installed but not running. For podman on macOS, run: podman machine start)
endif
[!Note]
Responses generated with Claude
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in the Makefile at the container tool availability check and review how it runs before targets such as deploy-olm and undeploy-olm. Verify the check tests runtime readiness for the selected container tool, then exercise the relevant Make targets with a stopped runtime to confirm destructive operations are not reached first.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker
- Domain
- build-system, devops
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 78/100