This method shows how to install Drupal and TheMAG theme from an existing configuration. This method requires
If you already have Drush 8, you can install a site-local Drush 9 by running
composer require drush/drush from your Drupal root directory. Otherwise, please refer to Drush documentation page for more information on how to install Drush.
$config_directories['sync'] = 'sites/default/themag_config';
drush site:install --existing-config --db-url=mysql://db_user:db_pass@localhost/db_name --account-name="demo" --account-pass="demo"
Change the db_user, db_pass, db_host and db_name with your database info. The --account-name will be you Drupal username and the --account-pass your Drupal password. This Drush command will install the Drupal and will import TheMAG configuration.
On production site, and if your account has permission to do so, it's a good idea to move the configuration sync directory outside of the webroot entirely. If you move the directory ouside of your web root, open up your settings.php file and change the sync location to: e.g.
$config_directories['sync'] = '../mysite/config/sync';