LinuxCommandLibrary

lando

Local development environment management and automation

TLDR

Initialize code for use with lando

$ lando init
copy

Print information about your app
$ lando info
copy

Start your app
$ lando start
copy

Stop your app
$ lando stop
copy

Restart your app
$ lando restart
copy

Rebuild your app from scratch, preserving data
$ lando rebuild
copy

Display logs for your app
$ lando logs
copy

Destroy your app
$ lando destroy
copy

SYNOPSIS

lando [options] command [arguments]

PARAMETERS

--verbose
    Increases the verbosity of Lando's output.

--debug
    Displays detailed debugging information for troubleshooting.

--clear
    Clears internal Lando caches before executing a command.

--help, -h
    Displays help information for a specific command or Lando itself.

--version, -v
    Shows the currently installed Lando version.

init
    Initializes a new Lando application in the current directory, typically by creating a .lando.yml file.

start
    Starts the services defined for the current Lando application.

stop
    Stops the services of the current Lando application without destroying data.

destroy
    Completely stops and removes all containers and data volumes associated with the application.

rebuild
    Rebuilds an application's services, useful after configuration changes.

info
    Displays detailed information about the application, including URLs and service access details.

logs [service]
    Shows logs for the application's services. Optionally specify a service name.

ssh [service]
    Provides SSH access to a specific service container (e.g., appserver, database).

db-import filename
    Imports a database dump from the specified file into the application's primary database service.

db-export [filename]
    Exports the application's database to a file. If no filename is provided, it exports to stdout.

tool
    Executes a command defined as a tool in the Lando configuration. Examples: lando composer install, lando drush status, lando npm run dev.

DESCRIPTION

Lando is a powerful, open-source command-line interface (CLI) tool designed to streamline local development for web applications. Built on Docker, it abstracts away the complexities of Docker Compose, providing a user-friendly way to define, build, and manage multi-service application environments. Developers specify their desired services (e.g., PHP, MySQL, Node.js), tools, and custom commands within a .lando.yml configuration file located at the project root. Lando then handles the orchestration, network setup, and provisioning of these services, ensuring consistent and reproducible environments across different machines and team members. It offers pre-configured "recipes" for popular frameworks like Drupal, WordPress, Laravel, and Symfony, enabling quick setup. Key features include automatic proxying for web access, built-in tooling for common development tasks (e.g., composer, drush, npm), and extensibility to define custom commands. Lando significantly simplifies local development workflows, making it an indispensable tool for modern web development.

CAVEATS

Lando requires Docker Desktop or Docker Engine to be installed and running on the host machine. It can consume significant system resources (RAM, CPU, disk space) as it runs multiple isolated containers. Its behavior is highly dependent on the project-specific .lando.yml configuration file. Lando is not a core Linux utility and must be installed separately.

CONFIGURATION FILE (<B>.LANDO.YML</B>)

The central configuration file for a Lando application. Located at the root of a project, it defines all services (e.g., web server, database, cache), build steps, tooling, commands, and environmental variables required for the application. This file ensures consistency and reproducibility of development environments across different machines and team members.

RECIPES

Lando provides pre-configured 'recipes' that simplify setting up common application stacks. These recipes abstract away complex Docker configurations for popular frameworks like Drupal, WordPress, Laravel, Symfony, Node.js, and more, allowing developers to get started quickly with minimal setup.

PROXYING AND HOSTNAMES

Lando automatically sets up local DNS entries and proxy URLs for the web services running inside the containers. This allows direct access to the application in a web browser using easily memorable hostnames (e.g., appname.lndo.site), eliminating the need to manage port mappings manually.

HISTORY

Lando was initially developed by Tandem (formerly Thinkoom) and released as an open-source project. Its development began around 2016-2017 with the goal of simplifying Docker-based local development, particularly for PHP-based content management systems like Drupal and WordPress. It quickly gained traction due to its user-friendly CLI and powerful abstraction over Docker Compose. Over time, Lando expanded its support to a wide array of programming languages and frameworks, becoming a versatile tool for creating consistent and shareable development environments. Continuous development focuses on performance, stability, and expanding its ecosystem of pre-configured recipes and integrations.

SEE ALSO

docker(1), docker-compose(1), vagrant(1), npm(1), composer(1), drush(1), wp-cli(1)

Copied to clipboard