Skip to content

Instantly share code, notes, and snippets.

@kyletaylored
Created March 4, 2023 01:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kyletaylored/99d509a9a87e62c84aca9db64b5c3867 to your computer and use it in GitHub Desktop.
Save kyletaylored/99d509a9a87e62c84aca9db64b5c3867 to your computer and use it in GitHub Desktop.
Lando example config with PHP override and multiple databases
name: example
recipe: pantheon
config:
framework: drupal8
site: example
id: <SITE_UUID>
xdebug: true
php: 8.1
index: false
edge: false
cache: false
config:
vhosts: ./lando/config/nginx.conf.tpl
php: ./lando/config/php.ini
services:
database:
creds:
database: pantheon
run:
# Creates the extra databases as root since the app user does not have those privileges
- mysql -uroot -e "CREATE DATABASE IF NOT EXISTS custom_db_1; GRANT ALL PRIVILEGES ON custom_db_1.* TO 'pantheon'@'%' IDENTIFIED by 'pantheon';"
- mysql -uroot -e "CREATE DATABASE IF NOT EXISTS custom_db_2; GRANT ALL PRIVILEGES ON custom_db_2.* TO 'pantheon'@'%' IDENTIFIED by 'pantheon';"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment