Islandora-Devops / isle-dc

ISLE 8 - Dockerized Islandora 8 Deployment orchestrated with docker-compose
MIT License
22 stars 60 forks source link

Properly configured Drupal - Islandora & Drupal installation scripts to be merged #23

Closed g7morris closed 4 years ago

g7morris commented 4 years ago

Additionally @nikathone has some good thoughts and ideas about work using the drupal image entry-point.sh which he can either open up a new ticket for or add here for further discussion as needed.

g7morris commented 4 years ago

@nikathone Please note, the composer.json and .lock files that are in that directory with @dannylamb 's install-islandora.sh script will be removed from here post-merge as they are just placeholders now. I believe your current drupal_init process in the Makefile and install script pulls from the born-digital Github repo https://github.com/Born-Digital-US/drupal-project which is what we want to preserve. Apologies for confusion but this is also on my radar to fix. Let me know if you need further clarification here.

nikathone commented 4 years ago

After reviewing https://github.com/Islandora-Devops/isle-dc/blob/06b877b0f010ba6d7884b19e2de6f65c39f0a7c6/scripts/islandora/install-islandora.sh to check what we will need to preserve/reuse in the drupal docker entrypoint. I think

  1. The Drupal init script should take care of the following scripts if not done yet:
    
    echo "Clone drupal-project to /var/www/html"
    git clone -b isle8-dev https://github.com/Born-Digital-US/drupal-project.git /var/www/html
    chmod 755 /var/www/html/composer.*

TO DO: mkdir theme dir and other necessary sub-folders

cd /var/www/html || exit

echo "composer update && installing Drupal console" composer update chmod u+w web/sites/default composer require drupal/console:~1.0 --prefer-dist --optimize-autoloader


2. The other part of the install script enable various modules and set Drupal configurations. Most of these should be taken care by the [starter configs](https://github.com/nikathone/isle-dc/blob/development/config/drupal/islandora-starter-config.tar.gz). If not the case we should regenerate them.

The [`init.sh`](https://github.com/nikathone/isle-dc/blob/development/scripts/drupal/init.sh#L167-L170) ensure that the starter config is added to the drupal codebase then the [`install_drupal`](https://github.com/Islandora-Devops/isle-nginx-php-base/blob/master/drupal_bin/install_drupal#L34) bash script will make sure that the website is installed based on [existing configuration](https://www.drupal.org/node/2897299).

3. Once we have confirmed that the config starter includes all the needed configurations we will then need to:
    * Deal with [Copy openseadragon library definition](https://github.com/Islandora-Devops/isle-dc/blob/06b877b0f010ba6d7884b19e2de6f65c39f0a7c6/scripts/islandora/install-islandora.sh#L69-L70)
    * and [Run migrations](https://github.com/Islandora-Devops/isle-dc/blob/06b877b0f010ba6d7884b19e2de6f65c39f0a7c6/scripts/islandora/install-islandora.sh#L114-L115)

If everybody agree with the above, after https://github.com/Islandora-Devops/isle-dc/pull/6 merge we can confirm that the configuration starter is complete and create a separate issue if it's not then have a separate issue for point 3 and close this one.

Tagging @dannylamb cause we might need his feedback.
dannylamb commented 4 years ago

I'm good with pushing all the config and module enabling to core drupal sync machinery. When going dev -> stage -> prod it makes a lot more sense.

...and maybe I'm being paranoid, but let's at least keep a copy of that init script in history. Rather not shoot my future self in the foot when something goes bad and I need to completely rebuild.

g7morris commented 4 years ago

Also depends on https://github.com/Islandora-Devops/isle-dc/issues/21

g7morris commented 4 years ago

@dannylamb & @nikathone What are the next steps with this?

nikathone commented 4 years ago

I @dannylamb is working on getting this done