Information for: DEVELOPERS   PARTNERS

Getting started with Cloud IDE

Cloud IDE requires Dev Studio.

After installing Dev Studio CLI, complete the following steps to install and configure Cloud IDE, after which you can begin to develop your Cloud Platform application based on the new integrated development environment (IDE):

Setting up Cloud IDE

To install your integrated development environment (IDE), complete the following steps:

  1. Sign in to the Cloud Platform.
  2. Open your local terminal application.
  3. Generate a Cloud API token, and record a copy of your API Key and API Secret.
  4. From the command line, run ads api:setup and follow the prompts to provide your API Key and API Secret.
  5. From the command line, run ads ide:create. Enter a descriptive label for your IDE, and then select the application with Cloud IDE enabled.

The Dev Studio CLI will display both a link to your Cloud IDE and a link to your Drupal website’s public URL. You can open your Cloud IDE at any time by running the following command from your terminal:

ads ide:open

For information about changing preferences in Cloud IDE, see Settings and preferences.

Cloning your Cloud application to your IDE

After setting up your Cloud IDE, clone your Cloud Platform application to your IDE by completing the following steps:

  1. From the command line on your local computer, run the following command to open your Cloud IDE:

    ads ide:open
    
  2. In your Cloud IDE admin menu, go to Terminal > New Terminal.

  3. From the Cloud IDE terminal, run ads api:setup and follow the prompts to provide your API Key and API Secret.

  4. In the Cloud IDE terminal, generate a SSH key by running ads ssh-key:create.

  5. Run ads ssh-key:upload to add the SSH key to your profile.

    Note

    It can take several minutes for the Cloud Platform to make your SSH key available to all your applications.

  6. Clone your repository into the correct folder in the Cloud IDE with the following command, replacing [your-URL.git] with the Git URL of your repository:

    git clone [your-URL.git] /home/ide/project
    

    Note

    If you already have an existing Cloud Platform application, you can leverage ads refresh to automate cloning your Git repository and refreshing your code, database, and files from the Cloud Platform.

Cloning your application from a Github repository to your Cloud IDE

To clone your application from a Github repository to your Cloud IDE, complete the following steps:

  1. Copy the contents of your Cloud IDE SSH public key at /home/ide/.ssh/id_rsa_acquia_ide_<UUID>.pub. Make sure to replace the following example code with your own Cloud IDE SSH public key:

    $ cat /home/ide/.ssh/id_rsa_acquia_ide_<UUID>.pub
    ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDia6OKJKFQYmQysWWL6+bRpjfGbGHaYx3b9mdqhRxtBr9
    +q1TUUljNPX3dT6y+GsQEC4ImAhm82fPpFjEpwPGrM5+kvlk4zkLMV+TILnQXA9athf3CWPTCUQxyY9t5ZO
    wbmjRPhFeDKCVogSAjHdCoVRQfKOy1J0ffO+I7nnjVNbhMLfeL1PU1WZhyx4tBRweKX44QZA1hccrIfw0SV
    rXnJ72Gm/0SESnCaAkfnEjo8+wwyiSNfTFOfY/MrgkNjePaxTPP0LaFwoiGpfyNRNAd6w+ztfIQa34kfviT
    NCp4Us/cGrtLH6AYvrtVbIwToNdXvTPliz+D1GJYcaWlbfdwHselKDQffVbnYLbpgopWgDJjmy/ex0TG4Gv
    Qnn1CVHZayKbivuVT0sEgcWrOmyKcqpO2PlZ+W4SCpCdQZ3Tz6I0I+O9VKLF2lauKtjHkmpfOxI46YkLEA8
    6sTuK3s9cyt8irn9X/4ggV7D4PbiYdaweQMjRgQPVhLcB+dosDml750bnEGjjY1iFJwIbT69gF5zucrheIr
    zr6OarwPjwW1V314sKfszssjSYpablgYYm/8zOjowKpgf+6XS0Ug0aKePWRPUVfSdnn5fDBEr9U3K4r3cv5
    L6Ol0GIJVcfEi7Vq6OsmDxgiEfAzKdpXaHZBwacpATrawZ0DQqr58V/xCw== [email protected]
    4ba0-b737-13187c3c8b96-6799564b7d-rbn58
    
  2. Paste the SSH public key into the Key field at https://github.com/settings/ssh/new:

    Github's add new SSH key page

  3. You can clone your repository into the correct folder in the Cloud IDE with the following command, replacing [your-URL.git] with the Git URL of your repository:

    git clone [your-URL.git] /home/ide/project
    

    Note

    When pulling the code from an external Git repository, you can use ads refresh --no-code to only pull the database and files from your Cloud Platform application.

View your application within Cloud IDE by clicking Open Drupal Site in the admin menu. Then click Open site in a new tab to open the application in a new tab in your browser. Clicking Open Site in the IDE alone will open the application in the Preview pane.