Configuration

All WP Hoster options live in config/wphoster.php and are driven by environment variables. Key sections: paths, MySQL, WP-CLI, WordPress defaults, Cloudflare, timeouts, backups, integrity, agent, and feature flags.

Config file

config/wphoster.php

Main keys and env vars

Config keyEnv variablePurpose
base_domainWP_HOSTER_BASE_DOMAINBase domain for sites
server_ipWP_HOSTER_SERVER_IPServer IP for DNS A records
paths.sites_rootWP_HOSTER_SITES_ROOTBase directory for site roots
paths.nginx_sites_availableWP_HOSTER_NGINX_SITES_AVAILABLENginx config directory
paths.nginx_sites_enabledWP_HOSTER_NGINX_SITES_ENABLEDNginx enabled symlinks
paths.sshd_config_snippetsWP_HOSTER_SSHD_CONFIG_SNIPPETSSSH Match block directory
templates.assets_pathWP_HOSTER_TEMPLATE_ASSETS_PATHLocal plugins/themes for templates
php_fpm_socketWP_HOSTER_PHP_FPM_SOCKETPHP-FPM socket path
mysql.hostWP_HOSTER_MYSQL_HOSTMySQL host
mysql.root_userWP_HOSTER_MYSQL_ROOT_USERMySQL root user
mysql.root_passwordWP_HOSTER_MYSQL_ROOT_PASSWORDMySQL root password
wp_cli.pathWP_HOSTER_WP_CLI_PATHWP-CLI binary
wordpress.admin_userWP_HOSTER_WP_ADMIN_USERDefault WP admin username
wordpress.admin_passwordWP_HOSTER_WP_ADMIN_PASSWORDDefault WP admin password
cloudflare.tokenCLOUDFLARE_TOKENCloudflare API token
cloudflare.zone_idCLOUDFLARE_ZONE_IDCloudflare zone ID
cloudflare.proxiedCLOUDFLARE_PROXIEDProxied A records
notifications.slack_webhookWP_HOSTER_SLACK_WEBHOOKSlack for alerts
notifications.generic_webhookWP_HOSTER_WEBHOOK_URLGeneric webhook for alerts
notifications.emailWP_HOSTER_ALERT_EMAILAlert email

Timeouts

KeyEnvDefault
timeouts.command_defaultWP_HOSTER_COMMAND_TIMEOUT300 (5 min)
timeouts.wp_cli_downloadWP_HOSTER_WP_CLI_DOWNLOAD_TIMEOUT600 (10 min)
timeouts.provisioningWP_HOSTER_PROVISIONING_TIMEOUT1800 (30 min)
timeouts.cloningWP_HOSTER_CLONING_TIMEOUT3600 (60 min)
timeouts.backupWP_HOSTER_BACKUP_TIMEOUT1800 (30 min)

Backups

KeyEnvPurpose
backups.retention_daysWP_HOSTER_BACKUP_RETENTION_DAYSDays to keep backups (14)
backups.storage_diskWP_HOSTER_BACKUP_STORAGE_DISKlocal or s3
backups.encryptWP_HOSTER_BACKUP_ENCRYPTEncrypt at rest
backups.verify_after_backupWP_HOSTER_BACKUP_VERIFYVerify after create

Features

KeyEnvPurpose
features.cloudflare_dnsWP_HOSTER_FEATURE_CLOUDFLARE_DNSEnable Cloudflare DNS (true)
features.circuit_breakerWP_HOSTER_FEATURE_CIRCUIT_BREAKERCircuit breaker for external calls
agent.enabledWP_HOSTER_AGENT_ENABLEDInstall WP Hoster Agent (true)