Any Windows, Linux and Mac computer suitable for modern web development can run Lando. If this your first-time trial of this free, LAMP tool, it may take 30 mins or so just to install it -- but then, using it can be very fast, afterwards! The learning curve is not very steep.
Step 1: Install Lando following the docs https://docs.lando.dev/basics/installation.html
The following part should only take 15 minutes or so, it is s very fast.
Step 2: Create a directory wherever you keep projects on your system. Then cd into that directory, and run
lando init
This will launch the wizard. You should choose "remote git repo or archive" and of course paste the link to your Acquia repo.
When the wizard asks for the web-root, enter docroot
.
Step 3: Check out the feature branch to use (e.g. develop-sf
)
At this point, starting Drupal is as simple as typing lando start
. But there are some configuration you may need to edit.
- IMPORTANT Add the .lndo.site local url(s) to your computer’s
/etc/hosts
file (See Lando docs for more info: https://docs.lando.dev/config/proxy.html#working-offline-or-using-custom-domains)
127.0.0.1 my-project.lndo.site
Step 4: If you have not downloaded Acquia’s drush aliases, follow our docs to do so: https://docs.acquia.com/acquia-cloud/manage/ssh/drush/aliases/#downloading-drush-aliases
Step 5: To synchronize ACSF remote sites with your Lando, add drush aliases for the remote sites you want to work with. Read this doc for a quick how-to: https://gist.github.com/markf3lton/0f446eb0d953bb2eb12a8f10bdaabcef#file-acsf-to-local-md
Step 6: Mirror the host operating system’s drush aliases into your Lando development environment
IMPORTANT Edit the .lando.yml
and add the last 2 lines shown here:
name: civiccms
recipe: drupal7
config:
webroot: docroot
appserver:
build:
- mkdir -p ~/.drush
- ln -sf /app/drush/civiccms.aliases.drushrc.php ~/.drush/civiccms.aliases.drushrc.php
You will have to rebuild, which only takes a few seconds, like this:
lando rebuild
Step 6: Sync your remote Acquia Site Factory site to your local using standard drush commands:
drush sql-sync @civiccms.01live.bartrussell @self
drush rsync @civiccms.01live.bartrussell:%files/ @self:%files
The site should be visible at the civiccms.lndo.site url as shown below.