Description

This module allows to run Drush without being granted access to the machine it relies on. It may be useful on shared hosts that do not provide SSH access to servers.

Example:
* With Drush (regular), one connects to a server using SSH and runs: drush en views.
* With this module, one uses Drush on his own workstation and runs: drush @myserver web en views.

Requirements

Server Client
  • ctools
  • features
  • oauth
  • services
  • libraries
  • PHP not in safe-mode (if PHP < 5.4.0)
  • Drush 4.0.0+ (download from github)
  • Drush works best on Unix-like OS
  • PHP 5.3.3+
  • PHP compiled with curl
  • Drush 5.0.0+ (Pear instructions)
  • Drush works best on Unix-like OS

Quick installation

  1. On the server:
    1. Enable modules drushweb and oauth_common_providerui.
    2. wget https://github.com/drush-ops/drush/archive/7.x-5.9.zip
    3. unzip 7.x-5.9.zip
    4. mv drush-7.x-5.9/ sites/all/libraries/drush
    5. Go to /admin/reports/status and make sure Drush is detected. This path needs to be valid: sites/all/libraries/drush/drush.info.
    6. Grant yourself role Drush Webservice OAuth user.
    7. Go to /user/[your-uid]/oauth/consumer/add and add a consumer with callback http://example.net and context Drush Webservice. Note the key and the secret.
  2. On the client:
    1. Edit ~/.drush/aliases.drushrc.php
      $aliases['myserver'] = array(
        'uri' => 'http://example.net/myserver', // Your server URI.
        'oauth_key' => 'y4ZYMrw8VNMDsnkibMxwu8ZybS4GPzHV', // Your OAuth key.
        'oauth_secret' => 'JHjnXtfpLxrPCVwnjyn8dCQmsxNmgfEZ', // Your OAuth secret.
      );
      
    2. cp -R drushweb/ ~/.drush/drushweb
    3. drush cache-clear drush
    4. drush @myserver web en views --yes. Views should get enabled on the server and the command output should show up.

Please also have a look at sections 'Making the client user friendly' and 'Security considerations' in README.txt.

Step-by-step installation

See README.txt.

Related projects

Project information

Releases