5 2. Configuration
René Kreijveld edited this page 2026-09-25 16:19:53 +02:00

Configuration

All ddev-joomla scripts share a single configuration file located at:

~/.config/ddevjoomla/config

Configuration Options

Option Description Default
ROOTFOLDER The directory where your Joomla sites are stored. Every project gets its own subfolder here: <ROOTFOLDER>/<projectname> ~/Development/Sites
DOCROOT Optional document root subfolder created inside every new project folder (e.g. public, htdocs, web, public_html, docroot). Empty means the project folder itself is the document root empty
BACKUPFOLDER The directory where backups are saved. jbackup writes to <BACKUPFOLDER>/sites, jdbdump to <BACKUPFOLDER>/databases ~/Development/Backups
WEBSERVER Default webserver type for new sites (nginx or apache) nginx
INSTALLER_VERSION Version of the installer that created this file (do not edit) -

Example

# Configuration file for php development environment
# Generated at 2026-01-15 10:24:11
ROOTFOLDER=${HOME}/Development/Sites
DOCROOT=
BACKUPFOLDER=${HOME}/Development/Backups
WEBSERVER=nginx
INSTALLER_VERSION=2.2

With DOCROOT=public the same config would place a new project mysite like this:

${HOME}/Development/Sites/mysite/          <- project folder, holds .ddev
${HOME}/Development/Sites/mysite/public/   <- document root, holds the Joomla files

Document root

DOCROOT is optional. Leave it empty and the project folder itself is the document root, which is the classic DDEV Joomla layout. Give it a value and jaddsite creates that subfolder inside the project folder, puts the Joomla files there, and configures DDEV with --docroot. This is handy when your production hosting uses a document root subfolder and you want your local project to match.

A few things worth knowing:

  • DOCROOT is only read by jaddsite. Every other script determines the layout from the project's own .ddev/config.yaml, so changing DOCROOT never breaks existing projects, and projects with and without a document root subfolder can live side by side under the same ROOTFOLDER.
  • jclone mirrors the source project, not the config, so a clone gets the same layout as the project it was cloned from.
  • Most scripts work from both folders. jdbdump, jdbdumptable, jdbimp, jbackup, jclone, jphpswitch, joomlainfo, jsetconfig and jxdb find what they need whether you run them from the project folder or from the document root.
  • gosite takes you to the document root, since that is where the Joomla files are.
  • Database dumps are written to the document root, so they end up next to the Joomla files and are included in a document-root-only backup (jbackup -r).
  • DOCROOT may be missing from a config file written by an older installer. Scripts treat a missing value the same as an empty one.

Editing the Configuration

Open the file in any text editor:

nano ~/.config/ddevjoomla/config

Changes take effect immediately - scripts read the config file each time they run.

Checking the Configuration

Run jddev-status to see the values the scripts will use. It also checks whether the root folder and backup folder exist and whether WEBSERVER is a valid value, and shows how many DDEV projects are found under ROOTFOLDER:

jddev-status

See jddev-status for the full description.

Notes

  • ROOTFOLDER and BACKUPFOLDER can use ${HOME} or absolute paths.
  • The WEBSERVER setting is used as the default when creating new sites with jaddsite. You can always override it per-site with the -w flag.
  • DOCROOT applies to newly created projects only. To change the layout of an existing project, edit docroot: in its .ddev/config.yaml (or re-run ddev config --docroot=...) and move the site files accordingly.
  • Scripts will exit with an error if the configuration file is missing. If this happens, re-run the installer to recreate it.