Closed McFateM closed 6 years ago
Just adding a bit more detail... I have a CentOS 7 machine at home running Docker now and tried this build sequence there today... Same result as noted above. I get lots of these...
Drush was attempting to connect to:
Drupal version : 7.56
Site URI : http://default
PHP executable : /usr/bin/php
PHP configuration : /etc/php5/cli/php.ini
PHP OS : Linux
Drush script : /opt/drush-7.x/vendor/drush/drush/drush.php
Drush version : 7.4.0
Drush temp directory : /tmp
Drush configuration :
Drush alias files :
Drupal root : /var/www/html
Site path : sites/default
Going to try my hand at making some local modifications to work around this. I'll report back whatever the outcome.
Looks like the issue actually occurs earlier in the process...
root@6a66cf21f72b:/tmp# ./install_site.sh
Installing all Islandora modules
Installing Drupal Site
exception 'Drush\Sql\SqlException' with message 'Unable to find a matching SQL Class. Drush cannot find your database connection details.' in [error]
/opt/drush-7.x/vendor/drush/drush/commands/sql/sql.drush.inc:597
Stack trace:
#0 /opt/drush-7.x/vendor/drush/drush/commands/core/site_install.drush.inc(109): drush_sql_get_class()
OK, so maybe the problem here is not what I thought? I see that the $databases array in my settings.php file is empty...
$databases = array();
So I killed my terminal session and found that customize/linux_settings.php did indeed have an empty $databases = array(); statement. I edited the file and copied the $databases section from macosx_settings.php and then picked up the process from ,/install_site.sh... and it appears to be working.
Confirmed. With the addition of the $databases definition lifted from macosx_settings.php transplanted into linux_settings.php the build appears to work properly. I'm logged in to an Islandora instance on my CentOS 7 machine here at home.
@McFateM Thanks for this update and feedback. Per @br2490 's recent email, you're confirming that the settings.php file used during the build process doesn't work as expected. I'll be able to review tomorrow (Tuesday, Nov 21) and patch.
Looks like linux_settings.php have already been updated? I pulled a new copy of ISLE this morning for installation on my DGDocker1 platform and that new copy looks right.
Hmmm... I haven't changed anything since last Friday... Good that it is working though. Thanks for the update. Are we closing this ticket? Or should @br2490 retest?
Yes, I think this can be closed. I guess last week I pulled code sometime BEFORE the Linux settings change was made? In any case I think this issue is resolved now. Now having very odd issues documented in #33 so I'm focusing there right now.
Oops... need to re-open this issue. While the $databases statement appears to be correct in customize/web/site/linux_settings.php, in my case those statements are NOT finding their way into /var/www/html/sites/default/settings.php. And I find this to be the case in both of my Linux (on my DGDocker1 VM) and Mac (on my MacBook) copies.
I doubled checked the 'web' section of docker-compose.yml and verified in the case of Linux...
volumes:
- ./customize/web/apache/site.conf:/etc/apache2/sites-available/site.conf
- ./customize/web/site/linux_settings.php:/var/www/html/sites/default/settings.php
#- ./customize/web/site/macosx_settings.php:/var/www/html/sites/default/settings.php
- ./customize/web/site:/home/islandora/site
I checked my local copy of linux_settings.php and the $database definition looks correct there, but again, that definition is NOT in my /var/www/html/sites/default/settings.php file. However, if I add the definition to the file and run './install_site.sh' it appears to be working!
Oops...forgot to re-open above.
@McFateM Thanks for the update. I'll be reviewing the web build process today on a Centos 7 vagrant vm. I'll see if I can replicate and then patch this.
Okay @McFateM Thanks for finding this issue. I've patched and resolved it via this commit I had an erroneous blank settings.php copy overwriting the mounted one. D'ouh. Thus no drush connections etc. I've since tested on a CentOS 7 vm and working correctly now. Apologies for your sub-optimal experience but glad you caught it! Closing ticket.
I got my containers running on my MacBook and attempting the final "step", the ./install_site.sh portion of...
...but I run into a bunch of these:
This appears to have precipitated a number of other errors down the line. I also tried 'cd /var/www/html/sites/default' and running /tmp/install_site.sh but with the same results.
Perhaps we need to define a Drush alias, like @default, and invoke the drush commands using it?