When Drush is called, it goes over a set of bootstrap steps that are very similar to how Drupal bootstraps on a web request. Drush commands might require minimum bootstrap phase to run. Here is a simplified list of each of Drush's bootstrap steps based on the documentation at drush topic docs-bootstrap
:
DRUSH_BOOTSTRAP_DRUSH
: This is the minimum bootstrap phase. It just loads Drush configuration and core files.DRUSH_BOOTSTRAP_DRUPAL_ROOT
: This checks whether there is a valid Drupal's root directory available. It is useful for commands that deal with a whole Drupal installation and not a specific site at thesites
directory.DRUSH_BOOTSTRAP_DRUPAL_SITE
: This will load Drush's configuration of a specific site within thesites
directory of a Drupal project, but it won't loadsettings.php
.DRUSH_BOOTSTRAP_DRUPAL_CONFIGURATION
: This loads the site'ssettings.php
file.DRUSH_BOOTSTRAP_DRUPAL_DATABASE
: This connects to the site's database, so database queries...