Open Luehrsen opened 2 years ago
Checking this issue - I'm wondering if this is something that the WordPress Playground solves? https://developer.wordpress.org/playground/ @Luehrsen
No. At least not yet. Playground is not configurable as wp-env
is and deviates in a lot of important steps, that are non-trivial for dev-work. (SQL db, etc.)
With the advent of GitHub Codespaces I guess there will be some desire to use a prepackaged solution like wp-env to generate a more or less standardised development solution. I am aware of the irony to spawn a docker container that spawns a docker container. But in my eyes are the advantages that come with wp-env greater than the drawbacks that you have to span a lightweight container to initialise wp-env.
The purpose of this issue is to find and define the things that could/should be changed to make integration with codespaces possible and better.
The creation of a Dockerfile or the devcontainer.json is NOT within the scope of this issue.
WordPress URL https://github.com/WordPress/gutenberg/blob/f7b26abf34542fc0a801a2b48564e38c9685bda6/packages/env/lib/wordpress.js#L45
Codespaces forwards ports to custom URLs. Meaning a port
8888
is not accessible viahttps://codespaces-url.com:8888
, but via a special URL likehttps://codespaces-url-8888.com
. This warrants, that the complete install URL has to be customisable, ideally with an environment variable.