Rackspace Community

cloud images

Install And Use Drupal on Cloud Sites

Article ID: 670

Last updated on August 24, 2014

Authored by: Rackspace Support

NOTE: This article refers to the Cloud Sites Control Panel. You can access this interface from the Cloud Control Panel by clicking your username in the upper-right corner of the control panel and selecting Cloud Sites Control Panel.

NOTE: It's possible to use an easy one-click install process with Drupal on Cloud Sites instead of the instructions below. For more details, please see this blog post.

Prerequisites

Administrative access to the Rackspace Cloud to create domains and add databases

To integrate Drupal to the root of domain (e.g. http://example.com/), place all contents of the unzipped Drupal directory (but excluding the directory itself) into the root directory of web/content.

To have the Drupal installation in its own subdirectory on the website (e.g. http://example.com/info/), rename the directory drupal to the name of choice and place it on the web server, for e.g. for drupal in a subdirectory called "info", rename the directory called "drupal-xx" to "info" and upload it to /web/content/.

Note the database information a) database name b) user name c) password d) hostname (not localhost) for use during the Drupal installation.

With this, Cloud Sites specific steps are complete. We can get started with the installation of Drupal.

Duplicate/copy default.settings.php to settings.php in the /sites/default and ensure write permissions on settings.php

Visit the index page of the website, e.g. visit: http://www.example.com/info

If DNS is not setup for the domain, use the Testing URL, e.g. visit: http://www.example.com.php5-7.dfw1-1.websitetestlink.com/info. The installation page will show up.

Follow on screen prompts to continue the installation.

Select the language to complete the install and run the application.

Make any necessary changes after the install script has checked permissions on the /sites/default directory.

Enter database connection information by clicking on the Advanced Options link and changing the Database Host field from "localhost" to the appropriate database hostname. Drupal will now create the required tables for the site's database.

After the installation completes, revert permissions on the /sites/default directory and configuration file back to 755 for security purposes if needed.

To use "clean URLs" through mod_rewrite, modify Drupal's .htaccess file. After "RewriteEngine on," ensure there is a "RewriteBase /" on the next line. If the Drupal install is in a sub-directory, then include the subdirectory e.g. "RewriteBase /info".

Drupal is fully functional and the software can now be accessed based on where it was installed

If Drupal files are placed in the root directory, e.g. visit: http://www.example.com

If Drupal is in its own subdirectory called info, e.g. visit: http://www.example.com/info

If DNS is not setup for the domain, visit the Testing URL provided in the Classic Cloud Control Panel under then General Settings tab, e.g. http://www.example.com.php5-7.dfw1-1.websitetestlink.com/info

Sign in as the administrator and customize site as needed.

For better performance and to reduce use of compute Cloud Sites compute cycles, turn on normal caching.