-2

I just installed Drush 9 on my ubuntu 19 machine. I also downloaded the latest Drupal 7 and 8 to my /var/www/html folder. My mysql is verified working. Is there a quick drush command to help me setup my databases without me having to manually create them for each drupal instance? I have access to my root user if needed.

  • 1
    If you want create database via drush there is command drush sql:create --db-su=root --db-su-pw=rootpassword --db-url="mysql://drupal_db_user:drupal_db_password@127.0.0.1/drupal_db" check the documentation here drushcommands.com/drush-9x/sql/sql:create – berramou Jun 27 at 21:51
0

You can find the docs here: https://drushcommands.com/drush-9x/sql/sql:create/

drush sql:create --db-su=root --db-su-pw=rootpassword --db-url="mysql://drupal_db_user:drupal_db_password@127.0.0.1/drupal_db"

It works on drush v8 as drush v9 doesn't support Drupal 7.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.