Skip to content

Commit

Permalink
Merge pull request #7557 from kaovilai/detectPodmanEmulation
Browse files Browse the repository at this point in the history
Add notes for podman / colima usage on macOS
  • Loading branch information
shubham-pampattiwar authored Mar 25, 2024
2 parents 24941b4 + 8f8bc9f commit f1f7f04
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,18 @@ else
GCR_IMAGE_TAGS ?= $(GCR_IMAGE):$(VERSION)
endif

# check buildx is enabled
# macOS/Windows docker cli without Docker Desktop license: https://github.com/abiosoft/colima
# To add buildx to docker cli: https://github.com/abiosoft/colima/discussions/273#discussioncomment-2684502
ifeq ($(shell docker buildx inspect 2>/dev/null | awk '/Status/ { print $$2 }'), running)
BUILDX_ENABLED ?= true
# if emulated docker cli from podman, assume enabled
# emulated docker cli from podman: https://podman-desktop.io/docs/migrating-from-docker/emulating-docker-cli-with-podman
# podman known issues:
# - on remote podman, such as on macOS,
# --output issue: https://github.com/containers/podman/issues/15922
else ifeq ($(shell cat $(shell which docker) | grep -c "exec podman"), 1)
BUILDX_ENABLED ?= true
else
BUILDX_ENABLED ?= false
endif
Expand Down

0 comments on commit f1f7f04

Please sign in to comment.