Provisioning
provision installs Drupal on the assembled codebase with your extension enabled, and prints a one-time login link when it finishes. Run it on its own to get a clean site without reassembling the codebase:
- Make
- Ahoy
- No wrapper
make provision
ahoy provision
vendor/bin/eddy-provision
What it does
- It installs Drupal from the
standardprofile into a fresh SQLite database, with anadminaccount and without the Update Status module. SetDRUPAL_PROFILEto install from another profile. - It enables your extension, as a module or as a theme.
- It enables each
drupal/*extension in thesuggestsection of yourcomposer.json, as a module or as a theme (see Optional dependencies). - It requests the front page once, so the caches are warm before you open the site.
- It links Drupal's browser test output into
.logs/browser_output, next to the other test artifacts. - It adds the reverse-proxy and trusted-host settings that a public tunnel needs, when the tunnel is on.
- It runs your
scripts/provision-*.shlifecycle scripts. - It prints the site URL and a one-time login link.
The database
The site keeps its data in an SQLite file at /tmp/site_<extension>.sqlite, named after your extension's machine name. Each provision starts it from scratch. DB Browser for SQLite can open it when you want to look inside.
Running Drush
drush runs a Drush command against the site, with the site URL already set:
- Make
- Ahoy
- No wrapper
make drush status
make drush cr
make drush -- status --format json
ahoy drush status
ahoy drush cr
ahoy drush status --format=json
build/vendor/bin/drush -l "$(vendor/bin/eddy-info site-url)" status
make reads an argument that holds = as a variable of its own, so put -- before the options and separate an option from its value with a space, as in make drush -- status --format json. An argument that holds : fails, so use the command's alias, such as cr for cache:rebuild. Ahoy passes the arguments through as they are.
Logging in
login prints a one-time login link for the admin account:
- Make
- Ahoy
- No wrapper
make login
ahoy login
build/vendor/bin/drush -l "$(vendor/bin/eddy-info site-url)" uli
Set LOGIN_QRCODE=1 in .env or your shell to have make login and ahoy login draw the link as a QR code too, which is handy for opening the site on a phone over a public tunnel. The wrappers only check that the variable is set, so unset it to turn the QR code off rather than setting it to 0. The QR code needs qrencode on PATH.