Sign inSign up

portlandwebworks/drupal-drush

By portlandwebworks

•Updated about 9 years ago

A Drush development image for Drupal 7 and Drupal 8

Image
0

461

portlandwebworks/drupal-drush repository overview

⁠THIS IMAGE IS DEPRECATED.

Use of this image is discouraged. This image is kept to support projects that have not yet moved to a newer setup. The image may be removed without notice.

⁠Drupal Drush PHP 5.6 Dev

⁠Overview

A Drush development image configured for Drupal 7 and PHP 5.6.

⁠Usage

  • Mount a directory containing your public key file named id_rsa.pub to /var/drush.
  • Mount the Drupal root directory to /var/www/html.
  • Update your ssh config, hosts file and Drush aliases to point to this container.

Note that Drush will use the mounted Drupal's settings.php for credentials. Provide the necessary information to Drush via environment variables.

⁠Support files templates
⁠Hosts
127.0.0.1 local.yoursite.com
⁠ssh config
Host local.yoursite.com
     Port 2222
     User root
     IdentityFile ~/.ssh/yourprivatekey
⁠Drush alias
$aliases['local'] = [
    'remote-host' => 'local.yoursite.com',
    'remote-user' => 'root',
    'ssh-options' => '-p 2222',
    'db-url' => '',
    'root' => '/var/www/html',
    'uri' => 'http://local.yoursite.com',
    'path-aliases' => [
        '%dump-dir' => "/tmp/backup",
        '%dump' => '/tmp/backup/db.sql'
    ],
];

⁠Compose

version: '2'
services:
  project-drush:
    build: portlandwebworks/drupal-drush:d7
    ports: 
      - "2222:22"
    environment:
      - MYSQL_HOST=project-mysql
      - MYSQL_DATABASE=db_name
      - MYSQL_USER=user
      - MYSQL_PASSWORD=password
      - MYSQL_PORT=3306 
      - PROJECT_DOMAIN=local.yoursite.com
    links:
      - project-mysql
      - project-apache
    volumes:
      - path/to/public/key/dir:/var/drush
      - path/to/site:/var/www/html

⁠Run

docker run -d -v path/to/public/key/dir:/var/drush -v path/to/site:/var/www/html portlandwebworks/drupal-drush:d7

Tag summary

Content type

Image

Digest

Size

191.8 MB

Last updated

about 9 years ago

docker pull portlandwebworks/drupal-drush:d7