#
Drupal Hosting Reference Guide
We provide optimized server environments for running Drupal. As the hosting provider, we maintain the server and infrastructure, but Drupal configuration, upgrades, and customization are your responsibility.
This guide explains where Drupal is installed on TurboStack, how to use the CLI, and how to manage permissions.
#
File Structure
Your Drupal installation resides in the following directories:
Note: In multi-site configurations, additional directories may exist under
~/public_html/sites/.
#
Installing Composer Dependencies
Drupal uses Composer to manage PHP dependencies and modules.
To install dependencies:
cd ~/public_html
composer install
To update dependencies:
composer update
Make sure you set a supported PHP version and have installed all required extensions for Drupal.
#
Permissions
Drupal requires proper permissions for the file upload directory.
Run the following to ensure correct access:
find ~/public_html -type f -exec chmod 644 {} \;
find ~/public_html -type d -exec chmod 755 {} \;
chmod -R 775 ~/public_html/sites/default/files
chown -R $USER:$USER ~/public_html
This ensures:
- Files are readable by the web server
- Directories are accessible
- The
filesdirectory is writable for uploads and generated assets
#
Caching
Drupal includes an internal caching system. Clearing caches is commonly required after installing modules or deploying configuration.
#
Clearing Drupal Cache
Use Drush:
drush cr
#
Redis and Varnish Caching
For improved performance, we recommend using Redis and optionally a reverse proxy such as Varnish. Both these options can be easily configured in the TurboStack App.
While Varnish works out-of-the-box, Redis needs to be specifically configured in your application. You can find our documentation on how to configure Redis caching here
More info on Varnish can be found here
#
Clearing Redis and Varnish Caches
If enabled in your environment:
tscli redis clear
tscli varnish clear
These commands flush Redis and Varnish caches respectively.
#
Running Scheduled Tasks (Cron)
Drupal relies on cron jobs to perform periodic tasks such as indexing, sending emails, and cleaning logs.
Run cron manually with:
drush cron
You may configure a user cron job if needed:
crontab -e
Example:
*/15 * * * * cd ~/public_html && drush cron
This example runs Drupal cron every 15 minutes.
#
Nginx Configuration
You can place custom Nginx configuration files in:
~/nginx
These configurations allow you to customize routing, caching behavior, or security headers for your Drupal installation.
Changes to Nginx configuration may require a reload by our infrastructure, which can be done with the `tscli nginx reload' command.
More information on Nginx configuration can be found here
If you need a separate staging server, additional PHP modules, or caching setup, please contact our support team!