Lando is an extremely flexible local development environment that is based on Docker. If your system can run Docker, then you can run Lando regardless if you are on a Mac, Windows, or Linux machine. The beauty of Lando is that most of the Docker configuration is handled for you through prebuilt "recipes", which greatly simplifies the setup process.
This repository contains the Lando configuration file (.lando.yml) that I use for my WordPress projects along with the php.ini file that it references.
These steps assume that Lando is already installed.
- Download a zipped copy of this repository and copy the
.lando.ymlandphp.inifiles to your project root. - Open up
.lando.ymland rename the app'snameto something unique. - Specify the desired PHP version, web server (apache or nginx), and database server (mysql, mariadb, or mongodb).
- Change the proxy from
wpsandbox.testto your desired domain. - Update your hosts file so that the app's domain points to 127.0.0.1 (
echo '127.0.0.1 wpsandbox.test' | sudo tee -a /etc/hosts). - Run the command
lando startfrom the project root.
Refer to Lando's extensive documentation.