openeuropa / drupal-site-template

OpenEuropa template for Drupal sites.
European Union Public License 1.2
12 stars 10 forks source link

Unable to perform the installation #31

Closed davidjguru closed 5 years ago

davidjguru commented 5 years ago

I was trying to install the Drupal Site from this repo, but is not possible due to errors related with Drush. I follow the steps until: ./vendor/bin/run toolkit:install-clean, Just when is creating the database (I guess)...get an error. davidjguru_drupal_8_openeuropa

I 've created a database called "openeuropa" in my mysql server and I review the .env file with the connection values. All is ok. Is there any reference about this problem? Any tutorial? More info?

Stack: OS: Ubuntu 18.04.2 Apache: 2.4.29 PHP: 7.3.5 Database: Mariadb 15.1

davidjguru commented 5 years ago

Well, ok, I got It done :-D I took instructions from here and there and mixing them, I have managed to boot Drupal Site Template in my environments. Now I have a centralized recipe. I put it here, in case someone needs it.

Environment:

OS - Ubuntu 18.04 PHP - 7.3.5 (but the container will run with its own PHP 7.1).

Prerequisites:

Docker Docker Compose

Installing Docker

sudo apt install -y build-essential apt-transport-https ca-certificates jq curl software-properties-common file curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" sudo apt update sudo apt install -y docker-ce sudo chmod 666 /var/run/docker* systemctl is-active docker

Installing Docker Compose

VERSION=$(curl --silent https://api.github.com/repos/docker/compose/releases/latest | jq .name -r) DESTINATION=/usr/local/bin/docker-compose sudo curl -L https://github.com/docker/compose/releases/download/${VERSION}/docker-compose-$(uname -s)-$(uname -m) -o $DESTINATION sudo chmod 755 $DESTINATION docker-compose --version

First: You have to stop your Apache webserver, in order to free the port:80

sudo /etc/init.d/apache2 stop

Second: Clone the Drupal Site project inside your working directory

git clone https://github.com/openeuropa/drupal-site-template.git

Third: Run the project (general and the web container for Drupal)

cd drupal-site-template docker-compose up -d docker-compose exec web composer install

Fourth: Get the ID of the web container and inspect it

docker ps docker container inspect IDCONTAINER

Fifth: Get the IP of the container and see it in browser

sensible-browser IPCONTAINER:8080

Sixth: Connect to the container

docker exec -it IDCONTAINER /bin/bash

Seventh: Run the installer / Task Runner

./vendor/bin/run toolkit:install-clean

Eighth: Export configuration files from database to config/sync

./vendor/bin/drush cex

Ninth: Visit your new project in

http://IPCONTAINER:8080/web

Happy Hacking!

voidtek commented 5 years ago

Issue resolved.