Based on: chriszarate/docker-wordpress-vip-go.
This repo provides a Docker-based environment for WordPress development. It provides WordPress, MariaDB, and WP-CLI.
-
Clone this or fork this repo and follow instructions. It is required to build an external network for proxy, so you can simultaneously run multiple projects on your local environment
-
Copy
sample.env
to.env
and provide your project title, domain name (same as in step 1), database port (unique for every instance of this repo), and GitHub repo, which contains your VIP Go ready project. -
Run
./bin/setup.sh
. -
Run
docker-compose up -d
.
docker-compose run --rm wp-cli install-wp
Log in to http://project.local/wp-admin/
with [email protected]
/ admin
.
You will probably want to create a shell alias for this:
docker-compose run --rm wp-cli wp [command]
If your stack is not responding, the most likely cause is that a container has stopped or failed to start. Check to see if all of the containers are "Up":
docker-compose ps
If not, inspect the logs for that container, e.g.:
docker-compose logs wordpress
Running ./bin/helpers/update_projects.sh
again can also help resolve problems.