Drush Cloud reference

Using Acquia Cloud Drush commands, you can use all of the features of the Cloud API on the command line or from shell scripts, using the Drush command-line tool. This reference describes only the Acquia Cloud Drush commands for using the Cloud API.

Acquia Cloud API commands

API credentials
ac-api-loginStore Acquia Cloud API credentials and configuration information.
Code deployment
ac-code-deployDeploy code from one site environment to another.
ac-code-path-deployDeploy a specific branch or tag in an environment.
Database commands
ac-database-addAdd a database.
ac-database-copyCopy a database from one site environment to another.
ac-database-deleteDelete a database.
ac-database-infoShow information about a site database.
ac-database-instance-backupCreate a backup of a database instance.
ac-database-instance-backup-deleteDelete a database instance backup.
ac-database-instance-backup-downloadDownload a database instance backup of a site environment.
ac-database-instance-backup-infoShow information about a site environment's database instance backup.
ac-database-instance-backup-listList a site environment's database instance backups.
ac-database-instance-backup-restoreRestore a database instance from a backup.
ac-database-instance-infoShow information about a site environment's database instance.
ac-database-instance-listList a site environment's database instances.
ac-database-listList a site's databases.
Domains
ac-domain-addAdd a domain name to an environment.
ac-domain-deleteDelete a domain name from an environment.
ac-domain-infoShow information about a site domain.
ac-domain-listList a site's domains.
ac-domain-moveMove one or more domains from one site environment to another.
ac-domain-purgePurge a domain from the Varnish cache.
Environments
ac-environment-infoShow information about a site environment.
ac-environment-installInstall a Drupal distribution from a preselected list, URL, or Drush Makefile.
ac-environment-listList a site's environments.
ac-environment-livedevEnable or disable live development on a site environment.
Files
ac-files-copyCopy files from one site environment to another.
Servers
ac-server-infoShow information about a server.
ac-server-listList servers for a site and environment.
Sites
ac-site-infoShow information about a site.
SSH keys
ac-sshkey-addAdd an SSH key to a site.
ac-sshkey-deleteDelete an SSH key from a site.
ac-sshkey-infoShow information about a site SSH key.
ac-sshkey-listList a site's SSH keys.
SVN users
ac-svnuser-addAdd an SVN user to a site.
ac-svnuser-deleteDelete an SVN user from a site.
ac-svnuser-infoShow information about a site SVN user.
ac-svnuser-listList a site's SVN users.
Tasks
ac-task-infoShow information about a site task.
ac-task-listList a site's tasks.
API aliases
acquia-updateRetrieves and updates Drush aliases for all accessible Acquia Cloud sites..

Common options

All Acquia Cloud API commands have the following options:

Options --cainfo= Path to a file containing the SSL certificates needed to verify the ac-api-endpoint.
--caller= Acquia Cloud API caller name. Default is the current username.
--endpoint= Acquia Cloud API endpoint URL.
--format= Format to output the object. Use "var_export" for var_export, and "json" for JSON. If not provided, the output is printed in a human-readable format.
--email= Acquia Cloud API email address. See Cloud API authentication.
--key= Acquia Cloud API key. See Cloud API authentication.
--acapi-conf-path= By default, the ac-api-login command stores default option values for future Acquia Cloud API commands in $HOME/.drush/.acapi.drushrc.php. Use this option to specify a different file location.

Command detail

API credentials

ac-api-login

Description Store Acquia Cloud API credentials and configuration information. This command stores default option values for future Acquia Cloud API commands in $HOME/.drush/.acapi.drushrc.php. This is most useful for stashing your API email and key so you do not have to enter it every time. You can change the file location where this is stored using the acapi-conf-path option.
Arguments
Options Common options
--reset Discard any existing stored values from a previous call. Without this option, new values will be merged with existing values.

Code deployment

ac-code-deploy

Description Deploy code from one site environment to the target environment.
Arguments target The target environment.
Options Common options

ac-code-path-deploy

Description Deploy a specific branch or tag in an environment.
Arguments path The branch or tag to deploy.
Options Common options

Database commands

ac-database-add

Description Add a database.
Arguments db The name of the database.
Options Common options

ac-database-copy

Description Copy a database from one site environment to the target environment.
Arguments db The database.
target The target environment.
Options Common options

ac-database-delete

Description Delete a database. By default, creates a backup of each instance of the database before deleting it.
Arguments db The database.
Options Common options
--no-backup Do not make a final backup of each instance of this database before deleting it.

ac-database-info

Description Show information about a site database.
Arguments db Database name.
Options Common options

ac-database-instance-backup

Description Create a backup of a database instance.
Arguments db The database.
Options Common options

ac-database-instance-backup-delete

Description Delete a database instance backup.
Arguments db The database.
backupid The backup ID.
Options Common options

ac-database-instance-backup-download

Description Download a database instance backup of a site environment.
Arguments db The database.
backupid The backup ID.
Options Common options
--result-file= Save to a file; specify the full path in which to store the backup. If no path is provided, the backup is sent the standard output.

ac-database-instance-backup-info

Description Show information about a site environment's database instance backup.
Arguments db Database name.
backup The backup ID.
Options Common options

ac-database-instance-backup-list

Description List a site environment's database instance backups.
Arguments db Database name.
Options Common options

ac-database-instance-backup-restore

Description Restore a database instance from a backup.
Arguments db The database.
backupid The backup ID.
Options Common options

ac-database-instance-info

Description Show information about a site environment's database instance.
Arguments db The database name.
Options Common options

ac-database-instance-list

Description List a site environment's database instances.
Arguments
Options Common options

ac-database-list

Description List a site's databases.
Arguments
Options Common options

Domains

ac-domain-add

Description Add a domain name to an environment.
Arguments domain The domain name.
Options Common options

ac-domain-delete

Description Delete a domain name from an environment.
Arguments domain The domain name.
Options Common options

ac-domain-info

Description Show information about a site domain.
Arguments domain The domain name.
Options Common options

ac-domain-list

Description List a site's domains.
Arguments
Options Common options

ac-domain-move

Description Move one or more domains from one site environment to the target environment.
Arguments target The target environment to which you are moving the domains.
domains A comma-separated list of the domains to move, or * to move all domains in the source environment.
Options Common options

ac-domain-purge

Description Purge a domain from the Varnish cache.
Arguments domain The domain name.
Options Common options

Environments

ac-environment-info

Description Show information about a site environment.
Arguments
Options Common options

ac-environment-install

Description Install a Drupal distribution into an environment from a URL or a Drush Make file.
Arguments type Type of distro source. One of distro_url or make_url.
source Depending on type, one of:
  • distro_url — A publicly accessible URL to any Drupal distribution in standard format.
  • make_url — A publicly accessible URL to a Drush Make file.
Options Common options

ac-environment-list

Description List a site's environments.
Arguments
Options Common options

ac-environment-livedev

Description Enable or disable live development on a site environment.
Arguments action The action to take: enable or disable live development on the environment.
Options Common options

Files

ac-files-copy

Description Copy files from one site environment to the the target environment.
Arguments target The target environment.
Options Common options

Servers

ac-server-info

Description Show information about a server.
Arguments server The server name.
Options Common options

ac-server-list

Description List servers for a site and environment.
Arguments
Options Common options

Sites

ac-site-info

Description Show information about a site.
Arguments
Options Common options

SSH keys

ac-sshkey-add

Description Add an SSH key to a site.
Arguments ssh_pub_key File containing the SSH public key.
nickname The SSH key nickname.
Options Common options

ac-sshkey-delete

Description Delete an SSH key from a site.
Arguments sshkeyid The ID of the SSH key to delete.
Options Common options

ac-sshkey-info

Description Show information about a site SSH key.
Arguments sshkeyid The ID of the SSH key.
Options Common options

ac-sshkey-list

Description List a site's SSH keys.
Arguments
Options Common options

SVN users

ac-svnuser-add

Description Add an SVN user to a site.
Arguments username SVN username.
password SVN password.
Options Common options

ac-svnuser-delete

Description Delete an SVN user from a site.
Arguments svnuserid The ID of the SVN user to delete.
Options Common options

ac-svnuser-info

Description Show information about a site SVN user.
Arguments svnuserid The ID of the SVN user.
Options Common options

ac-svnuser-list

Description List a site's SVN users.
Arguments
Options Common options

Tasks

ac-task-info

Description Show information about a site task.
Arguments task The task ID.
Options Common options

ac-task-list

Description List a site's tasks.
Arguments
Options Common options

API aliases

acquia-update

Description Retrieves and updates Drush aliases for all accessible Acquia Cloud sites.
Arguments
Options Common options