Configuration
Learn how to configure Wp Admin for your WordPress site, including environment variables, security settings, performance tuning, and backup policies.
Wp Admin uses a flexible configuration system that allows you to customize every aspect of your WordPress management setup. Configuration can be managed through the dashboard, environment variables, or a wpadmin.json configuration file.
Note
Configuration changes may take up to 5 minutes to propagate across all managed services. For immediate changes, use the wpadmin deploy --force command.
Quick Start
After installing the Wp Admin agent, follow these steps to configure your first WordPress site:
Create a Configuration File
Initialize a new wpadmin.json in your project root directory:
wpadmin init
Set Your API Key
Add your API key to the configuration or set it as an environment variable:
WPADMIN_API_KEY=wa_live_sk_abc123xyz789...
WPADMIN_SITE_URL=https://yourdomain.com
WPADMIN_ENVIRONMENT=production
Verify Connection
Test your configuration by running a health check:
wpadmin verify
â API key is valid
â Site URL is reachable
â WordPress version 6.4.2 detected
â Database connection successful
â All systems operational
Configuration File (wpadmin.json)
The wpadmin.json file is the primary configuration source. Here's a complete example:
{
"site": {
"url": "https://yourdomain.com",
"name": "My WordPress Site",
"environment": "production"
},
"security": {
"firewall": true,
"malware_scan": {
"enabled": true,
"schedule": "daily",
"scan_time": "03:00"
},
"login_protection": {
"enabled": true,
"max_attempts": 5,
"lockout_duration": 900,
"whitelist_ips": ["203.0.113.0/24"]
},
"two_factor": {
"enabled": true,
"enforce": true
}
},
"performance": {
"caching": {
"enabled": true,
"type": "redis",
"ttl": 3600
},
"cdn": {
"enabled": true,
"provider": "cloudflare",
"zone_id": "env.CLOUDFLARE_ZONE_ID"
},
"image_optimization": {
"enabled": true,
"format": "webp",
"quality": 80
},
"database": {
"optimization": true,
"cleanup_schedule": "weekly"
}
},
"backups": {
"enabled": true,
"frequency": "daily",
"retention_days": 30,
"storage": {
"type": "s3",
"bucket": "wpadmin-backups-prod",
"region": "us-east-1"
},
"includes": ["database", "uploads", "themes", "plugins"],
"notifications": {
"on_success": false,
"on_failure": true,
"channels": ["email", "slack"]
}
},
"updates": {
"auto_core": "minor",
"auto_plugins": true,
"auto_themes": true,
"staging_first": true,
"blacklist": [\