lhuria94 / docker-drupal-lamp

Standard image for Drupal docker lamp stack

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

docker-drupal-lamp

Minimal Drupal 7.x development environment stack.

How to use:

  1. Place a copy of this docker-compose.yml file at your Drupal site root or maybe create a folder "docker/".

  2. Build the image using 'docker build -t your_image_name .'

  3. Start the web stack: 'docker-compose up -d'

  4. To see your running containers: docker ps

  5. To get inside the container using bash: 'docker-compose exec web bash'

  6. For new installation:
    Add Database setup instructions while installing Drupal:

  • Database name = 'your_db_name'
  • Database username = 'root'
  • Leave database password blank
  • Expand "Advanced options" and set Database host = 'db' (This is defined in docker-compose.yml file)
  1. For existing installation:
    Import Database using:
    docker exec -i your_db_container mysql -uroot -proot your_db_name < filename.sql

  2. Make necessary changes in settings.php

  3. Run Drush commands with:

  • USER_ID=$(id -u) docker-compose run --rm drush $rest_of_the_command

About

Standard image for Drupal docker lamp stack

License:GNU General Public License v3.0