Working with sites on Acquia Cloud

Once you have a website with versions both locally in Acquia Dev Desktop and hosted in Acquia Cloud (which you can accomplish either by exporting a local website into Acquia Cloud or by creating a local clone of an Acquia Cloud website), you can use Acquia Dev Desktop to develop the website locally, while synchronizing the website continuously with the version on Acquia Cloud. This helps you coordinate your local workflow in Acquia Dev Desktop with your Acquia Cloud workflow.

Here's what a website looks like in Acquia Dev Desktop after you have either imported from Acquia Cloud or exported it to Acquia Cloud:

Acquia Cloud website in Acquia Dev Desktop

For information about the features displayed in this view, see Working with your sites.

Use the Local workflow section to push or pull between the local version of your website and the Acquia Cloud version. For more information about what happens when you push or pull, see How Acquia Dev Desktop works with Acquia Cloud.

Pushing to your Acquia Cloud Dev environment

As you develop your website locally, you can use Acquia Dev Desktop to push your changes to the version of the website on Acquia Cloud:

  1. Select Push to Cloud Dev.
  2. Select which elements of your website you want to update: Code, Database, and Files.
    By default, Clear cache is selected, so that the caches in your Acquia Cloud Dev environment are cleared, and your changes will become visible faster.
  3. Optionally, select Run update.php if you are adding or updating Drupal modules to your Acquia Cloud website.
  4. Click Push to Cloud Dev. Acquia Dev Desktop pushes your changes to the Dev environment of your Acquia Cloud website.
  5. You may be asked to enter your SSH key password, your name, and email address before your files will push. Enter the appropriate information when you are asked for it.

When you make a local copy of an Acquia Cloud website, Acquia Dev Desktop makes a modification to the website's settings.php file. This modification ensures that your local website connects to your local database, while your Acquia Cloud website continues to connect to the Acquia Cloud database. When you push your local code to Acquia Cloud, you need to commit this modified settings.php file so that both your local and Acquia Cloud database connections continue to function.

For more information about pushing your local website to Acquia Cloud, see Committing local changes to Acquia Cloud. If you run into problems, see Troubleshooting: Problems syncing sites with Acquia Cloud.

Pulling from your Acquia Cloud website

You can use Acquia Dev Desktop to pull the version of the website on Acquia Cloud into your local Acquia Dev Desktop website. The Code label specifies which tag or branch is currently deployed on the Acquia Cloud environment you're pulling from. Your Acquia Cloud website has a single code repository which is shared by each of your environments. Each environment can have a different tag or branch deployed.

  1. Select Pull from Cloud.
  2. Select which environment on your Acquia Cloud website you want to pull from (Dev, Stage, or Prod).
  3. Select which elements of your website you want to update: Code, Database, and Files.
  4. Optionally, select Run update.php if you are adding or updating Drupal modules to your local Acquia Dev Desktop website.
  5. Click Pull code from Cloud Dev. Acquia Dev Desktop pulls your changes from your Acquia Cloud website.

Which files get synced

When you pull files from Acquia Cloud or push files to Acquia Cloud, Acquia Dev Desktop syncs the files in these folders under your [docroot]:

  • /files
  • /sites/all/files
  • /sites/default/files (if you have no multisites) or /sites/[current multisite]/files (if you have multisites)

Since files don't belong to the codebase, they aren't tracked in the version control system (Git), and therefore aren't synced when you pull or push code. They are synced using rsync when you pull or push files.

Branch differences between Acquia Cloud and your local code repository

When you pull code from Acquia Cloud or push code to Acquia Cloud, it is possible that your local code repository may have a different branch checked out from the one that is currently deployed on your Acquia Cloud Dev or Stage environment. For example, you may have pulled code from Acquia Cloud and then another team member may have deployed a new branch on that environment.

Acquia Dev Desktop can only push code changes when the Acquia Cloud environment and your local code repository have the same branch deployed. If you try to push code from Acquia Dev Desktop to Acquia Cloud when the branches don't match, the push operation will fail with an error message. To change the Acquia Cloud branch:

  1. Click the Acquia Cloud Workflow button in Acquia Dev Desktop.
  2. Click the code select button on the application's Environments page.
  3. Select the branch you have checked out to your local code repository.

If you try to pull code from an Acquia Cloud environment when your local code repository already has a different branch checked out, then:

  • If you have no uncommitted code changes in your local code repository, Acquia Dev Desktop asks if you want to overwrite your local code repository with the deployed branch from your Acquia Cloud environment.
  • If you do have uncommitted code changes in your local code repository, the pull operation is not permitted.

Contact supportStill need assistance? Contact Acquia Support