Installing Varbase locally with DDEV
This guide walks you through installing Varbase 11.0.x on your local machine using DDEV, a Docker-based local development tool designed for PHP projects.
Prerequisites
Before you begin, make sure you have the following installed on your machine:
Docker: DDEV requires Docker (or a compatible container runtime such as Colima or OrbStack).
Install Docker Desktop from https://www.docker.com/products/docker-desktop/
DDEV: Install DDEV by following the official installation guide:
Step 1: Create the Project Directory
Create a new directory for your Varbase project and navigate into it:
mkdir my_varbase_site
cd my_varbase_siteReplace my_varbase_site with your desired project directory name.
Step 2: Configure DDEV
Run the DDEV configuration command with the following options:
ddev config --project-type=drupal11 --docroot=web --php-version=8.4This configures the project as a Drupal 11 site with:
Docroot:
web(the Varbase web root).PHP version:
8.4.Project name: Defaults to the directory name.
Step 3: Start DDEV
Start the DDEV environment:
This command pulls the required Docker images, creates the containers, and starts the development environment. The first run may take a few minutes.
Step 4: Create the Varbase Project
Use Composer inside DDEV to create the Varbase project:
This downloads Varbase and all of its dependencies (Drupal core, contributed modules, recipes, themes, and libraries) into the project directory.
The Varbase Installer will handle the Drupal installation and apply all Varbase recipes automatically, configuring the full feature set including:
Drupal CMS 2.0 recipes (admin UI, media, SEO, anti-spam, privacy, and more)
Varbase recipes (content, admin, media, editor, security, SEO, workflow, blog, and more)
Easy Email recipes for HTML email support
Vartheme BS5 front-end theme and Gin admin theme
Step 5: Launch Your Site
After the installation is complete, open your site in a browser:
Complete Installation Commands
Here are all the commands together for quick reference:
Useful DDEV Commands
ddev start
Start the project containers
ddev stop
Stop the project containers
ddev restart
Restart the project containers
ddev launch
Open the site in your default browser
ddev drush [command]
Run a Drush command inside the container
ddev composer [command]
Run a Composer command inside the container
ddev ssh
SSH into the web container
ddev describe
Show project information and URLs
Custom DDEV Commands for Varbase
ddev install-varbase
Installs Varbase from scratch using drush site:install varbase with the Varbase profile and Drupal recipes.
ddev init-full-automated-testing
Full initialization for automated testing. Handles everything from a fresh ddev start:
Installs Varbase if the database is empty
Applies optional Varbase recipes (
varbase_dev_base,varbase_i18n_base,varbase_api_base,varbase_auth_base,varbase_ai_base)Enables social auth modules (
social_auth_facebook,social_auth_linkedin)Adds testing users for each Varbase role
Disables the antibot module (required for automated browser testing)
Disables CSS/JS aggregation
Sets verbose error logging
ddev init-minimal-automated-testing
Minimal initialization for automated testing on an already installed site. Does not install Varbase or apply recipes:
Verifies Drupal is installed (exits with error if not)
Adds testing users for each Varbase role
Disables the antibot module
Disables CSS/JS aggregation
Sets verbose error logging
ddev add-testing-users / ddev delete-testing-users
Manage testing user accounts individually.
Troubleshooting
If
ddev startfails, ensure Docker is running and that no other services are using the same ports.Run
ddev powerofffollowed byddev startto reset the DDEV environment if you encounter persistent issues.Check DDEV logs with
ddev logsfor detailed error information.
Last updated