Varying-Vagrant-Vagrants / VVV

An open source Vagrant configuration for developing with WordPress
https://varyingvagrantvagrants.org
MIT License
4.54k stars 848 forks source link

WP Env support #2470

Open tomjn opened 3 years ago

tomjn commented 3 years ago

When a user specifies a repo that contains a wp-env.json VVV should attempt to process it and guestimate the correct setup as best it can.

Doing this means the new WordCamp and other sites would auto-magically work in VVV. Why compete with WP-Env when we can subsume it from the inside out?

Options include:

Mte90 commented 3 years ago

some examples of those wp-env.json files?

that file has just one parameter.

tomjn commented 3 years ago

some examples of those wp-env.json files?

Official WP Env documentation https://developer.wordpress.org/block-editor/reference-guides/packages/packages-env/

WordPress Developer Resources
@wordpress/env | Block Editor Handbook | WordPress Developer Resources
wp-env lets you easily set up a local WordPress environment for building and testing plugins and themes. It's simple to install and requires…
Mte90 commented 2 years ago

So I was trying to look on this, we are talking of a fork of https://github.com/Varying-Vagrant-Vagrants/custom-site-template that has that file. As today we don't have any example of this and VVV need a provisioner to do stuff.

Also looking at the doc page wp-env it is a command so maybe we need also to contribute on that project so can detect VVV and turn on xdebug as example.

tomjn commented 2 years ago

I believe that we should be able to provision with some basic options without any site template at all, and that if the repo specified is a WP Env based repo then it should try to provision accordingly, with a basic supported featureset.

I don't believe we should download and actually run WP-Env though, I have no interest in spinning up WP Env containers inside the VVV virtual machine

Mte90 commented 2 years ago

So to this I need a provisioner with this file so I can see how to implement it.

tomjn commented 2 years ago

no provisioner exists, we would have to build one and integrate it into provision-site.sh. This is a reverse engineering job