Opened 5 months ago
Last modified 8 weeks ago
#63883 new enhancement
Podman Local Environment Setup Scripts
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Awaiting Review | Priority: | normal |
| Severity: | normal | Version: | 6.9 |
| Component: | Build/Test Tools | Keywords: | 2nd-opinion |
| Focuses: | Cc: |
Description
Due to a restriction, Docker is cannot be installed on my Mac and Podman must be used.
The instructions for getting the local environment set up require the use of docker, https://github.com/WordPress/wordpress-develop/?tab=readme-ov-file#local-development.
We can add support for Podman via an argument would be helpful in the case that docker cannot be installed.
/tools/local-env/scripts/docker.js
Output:
WordPress@6.9.0 env:start
node ./tools/local-env/scripts/start.js && node ./tools/local-env/scripts/docker.js run -T --rm php composer update -W
/bin/sh: docker: command not found
/Users/<User>/wordpress-develop/tools/local-env/scripts/start.js:26
throw new Error( 'Could not retrieve Docker system info. Is the Docker service running?' );
Error: Could not retrieve Docker system info. Is the Docker service running?
at Object.<anonymous> (/Users/<User>/wordpress-develop/tools/local-env/scripts/start.js:26:9)
at Module._compile (node:internal/modules/cjs/loader:1469:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1548:10)
at Module.load (node:internal/modules/cjs/loader:1288:32)
at Module._load (node:internal/modules/cjs/loader:1104:12)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:174:12)
at node:internal/main/run_main_module:28:49
Node.js v20.17.0
Change History (2)
#2
@
8 weeks ago
I use OrbStack at the moment and it ships with Docker command-line tools so docker on the CLI continues to work (just using OrbStack as its context).
It looks like Podman doesn't do this, and uses its own podman command instead. If you create a docker alias that points to podman does everything work ok?
My concern with adding support for commands other than docker is it starts to look like official support.
Hi @andrewkarch,
Welcome to Trac!
In [60504]/#63641, a note was added tot he README mentioning that Podman should work without issue, but only Docker is currently supported:
I believe that something like this would fix this issue:
execSync( `${containerTool} info` );But I am not sure that I love this because it opens the door for some unknown use cases in the future that may prevent certain changes.
@johnbillion do you have any thoughts here?