From 6017a951d803d409eb6f00a2c3612c4a05087447 Mon Sep 17 00:00:00 2001 From: Finne Fortuin Date: Wed, 4 Jul 2018 15:29:04 +0100 Subject: [PATCH] add config_sync dir so drush works --- .lando.yml | 2 ++ init.sh | 9 +++++++-- sites.default.settings.php | 2 ++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/.lando.yml b/.lando.yml index d1f06cf..eb2dd87 100644 --- a/.lando.yml +++ b/.lando.yml @@ -20,6 +20,8 @@ services: environment: # Enable PHPStorm XDebug with CLI. PHP_IDE_CONFIG: "serverName=appserver" + # Set the Mink webdriver args. + MINK_DRIVER_ARGS_WEBDRIVER: '["chrome", null, "http://host.docker.internal:4444/wd/hub"]' database: # Add a static db port for easy bookmarking and access through SQL clients. portforward: 33006 diff --git a/init.sh b/init.sh index 44b7fd1..a3ac735 100644 --- a/init.sh +++ b/init.sh @@ -12,15 +12,17 @@ else cd web composer install - # Upgrade PHPUnit to work with PHP 7, add drush. - composer require --update-with-dependencies "phpunit/phpunit ^6.0" "drush/drush" + # Upgrade PHPUnit to work with PHP 7, add drush and selenium + composer require --update-with-dependencies "phpunit/phpunit ^6.0" "drush/drush" "joomla-projects/selenium-server-standalone" echo "Installing default site." # Create file dirs. cd $LANDO_MOUNT mkdir -p -m 777 web/sites/default/files + mkdir -p -m 777 web/sites/simpletest mkdir -p -m 777 files/private mkdir -p -m 777 files/tmp + mkdir -p -m 777 files/sync # Symlink the settings and public file dir. if [ ! -L "$LANDO_MOUNT/web/sites/default/settings.php" ]; then @@ -29,6 +31,9 @@ else if [ ! -L "$LANDO_MOUNT/files/public" ]; then ln -s $LANDO_APP_ROOT_BIND/web/sites/default/files $LANDO_MOUNT/files/public fi + if [ ! -L "$LANDO_MOUNT/files/simpletest" ]; then + ln -s $LANDO_APP_ROOT_BIND/web/sites/simpletest $LANDO_MOUNT/files/simpletest + fi cd $LANDO_MOUNT/web drush site-install diff --git a/sites.default.settings.php b/sites.default.settings.php index bc32d23..de848b5 100644 --- a/sites.default.settings.php +++ b/sites.default.settings.php @@ -778,6 +778,8 @@ # include $app_root . '/' . $site_path . '/settings.local.php'; # } +$config_directories[CONFIG_SYNC_DIRECTORY] = $app_root . '../files/sync'; + if (getenv('LANDO') === 'ON') { $lando_info = json_decode(getenv('LANDO_INFO'), TRUE); $databases['default']['default'] = [