Acquia CMS

Developing with Drupal Starter Kits and deploying to Cloud Next

This page describes how to develop a Drupal site in your local system or Cloud IDE by using Drupal Starter Kits. It also explains how to deploy the site to environments running on Cloud Next technologies.

Prerequisites

To deploy code changes from your local system to Cloud Next, you must install Acquia CLI. For more information, see Acquia CLI installation. However, if you are using Cloud IDE, you do not need to install Acquia CLI as it is pre-installed in Cloud IDE.

Developing your Drupal site by using Drupal Starter Kits

After you install Drupal Starter Kits by using one of the available starter kits, you can start developing your Drupal site.

To develop your Drupal Starter Kits-flavored Drupal site from your local system or Cloud IDE:

  1. Configure the settings.php file
  2. Set up the Cloud Next Git remote
  3. Commit code to the branch

Configuring the settings.php file

To configure the settings.php file:

  1. Make the settings.php writable.
  2. Remove the following code snippet:

    $databases['default']['default'] = array (
          'database' => 'drupal',
          'username' => 'drupal',
          'password' => 'drupal',
          'prefix' => '',
          'host' => '127.0.0.1',
          'port' => '3306',
          'namespace' => 'Drupal\\mysql\\Driver\\Database\\mysql',
          'driver' => 'mysql',
          'autoload' => 'core/modules/mysql/src/Driver/Database/mysql/',
          );
    
  3. Add the following require line:

    if (file_exists('/var/www/site-php')) {
    require '/var/www/site-php/eejohngalvin/eejohngalvin-settings.inc';
    }
    

    You can get this require line from the Cloud Platform user interface.

Setting up the Cloud Next Git remote

To set up the Cloud Next Git remote:

  1. Run the following commands sequentially:

    git init
    git remote add origin <remote_URL>
    

    Note

    • You can skip the git init command in Cloud IDE.
    • To obtain the remote URL in the Cloud Platform user interface, click View Git Information.

Committing code to the branch

To commit code to the branch:

  1. Run the following commands sequentially:

    git checkout -b branch
    git add .
    git commit -m "Initial Commit"
    git push origin branch
    

Deploying your site to Cloud Next

After your Drupal site is developed, you can deploy the site to Cloud Next by completing the following tasks:

  1. Push artifact
  2. Push databases
  3. Push files
  4. Deploy branch to the environment

Pushing the artifact

To push the artifact to Cloud Next:

  1. Run the following command:

    acli push:artifact --destination-git-branch=main-build
    

Pushing the database

To push the database to Cloud Next:

  1. Run the following command:

    acli push:db
    

Pushing files

To push files to Cloud Next:

  1. Run the following command:

    acli push:files
    

Deploying branch to the environment

To deploy the branch to the environment:

  1. Switch the code with the artifact branch.

Did not find what you were looking for?

If this content did not answer your questions, try searching or contacting our support team for further assistance.

Acquia Help

Filter by product:

Acquia CMS common questions