Skip to content

Commit

Permalink
drushrc.php in drupal image also with uri function based of `LAGOON…
Browse files Browse the repository at this point in the history
…_ROUTE`
  • Loading branch information
Schnitzel committed Jan 10, 2018
1 parent f51a456 commit 5b02a99
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions images/php/cli-drupal/drushrc.php
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
<?php
/**
* @file
* lagoon global drushrc.php file
* Lagoon global drushrc.php file
*
* This file tells drush about the lagoon environment
*/

$options['root'] = '/app/' . getenv('WEBROOT');
### Drush Root
$options['root'] = '/app/' . getenv('WEBROOT');

### Base URL so Drush knows on which URL the site runs (needed for cron, etc.)
if (getenv('LAGOON_ROUTE')) {
$options['uri'] = str_replace(['https://', 'http://'], ['', ''], getenv('LAGOON_ROUTE'));
}

0 comments on commit 5b02a99

Please sign in to comment.