upskill-event-manager/wordpress-dev
bengizmo 44b8d62722 docs: update Memory Bank and implementation plan with development environment progress
- Update activeContext.md with current focus and status
- Add development environment decisions to decisionLog.md
- Update progress.md with completed tasks
- Add development patterns to systemPatterns.md
- Update productContext.md with environment details
- Add Development Environment Setup section to implementation plan"
2025-03-25 14:28:26 -03:00
..
bin docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00
php.ini docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00
playwright-report docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00
tests docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00
dev-env.conf Initial commit: Implemented registration and login functionality 2025-03-25 10:56:29 -03:00
dev_env_proposal.md Initial commit: Implemented registration and login functionality 2025-03-25 10:56:29 -03:00
docker-compose.yml docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00
Dockerfile docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00
nginx.conf Initial commit: Implemented registration and login functionality 2025-03-25 10:56:29 -03:00
package-lock.json docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00
package.json docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00
php-fpm.conf docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00
README.md Initial commit: Implemented registration and login functionality 2025-03-25 10:56:29 -03:00
testing.md Initial commit: Implemented registration and login functionality 2025-03-25 10:56:29 -03:00
tsconfig.json docs: update Memory Bank and implementation plan with development environment progress 2025-03-25 14:28:26 -03:00

WordPress Development Environment

Status: Active/Authoritative Last Updated: March 12, 2025 Scope: Development environment setup and configuration

This is a Docker-based development environment for WordPress that replicates the production environment on Cloudways. It includes WordPress with PHP 8.1, MariaDB, and phpMyAdmin.

Prerequisites

  • Docker and Docker Compose
  • Git
  • Node.js and npm (for E2E tests)
  • mkcert (for SSL support, installed automatically if needed)

Environment Setup

1. Configuration

The .env file contains:

  • Production server details
  • Database credentials
  • WordPress authentication
  • SSL configuration
  • Development settings

2. Development Environment

# Start environment
./bin/setup-dev.sh

# Verify setup
./bin/verify-dev.sh

This creates:

  • WordPress (PHP 8.1-FPM)
  • MariaDB
  • phpMyAdmin
  • Nginx (with SSL support)

3. Plugin Setup

Required plugins are automatically synced from production:

  • The Events Calendar Suite (6.10.2+)
  • Event Tickets Suite (5.19.3+)
  • Additional required plugins

Access Points

Development Tools

Environment Management

# Setup development environment
./bin/setup-dev.sh

# Sync with production
./bin/sync-production.sh

# Verify environment
./bin/verify-dev.sh

# Setup SSL (if needed)
./bin/setup-ssl.sh

Testing

# Run all tests
./bin/run-tests.sh

# Run specific test suites
./bin/run-tests.sh --unit
./bin/run-tests.sh --integration
./bin/run-tests.sh --e2e

Database Operations

# Backup development database
./bin/backup-dev-db.sh

# Import production database
./bin/import-prod-db.sh

# Reset development database
./bin/reset-dev-db.sh

Troubleshooting

Common Issues

  1. Environment Issues

    # Check container status
    docker-compose ps
    
    # View container logs
    docker-compose logs
    
  2. Database Issues

    # Reset database
    ./bin/reset-dev-db.sh
    
    # Verify database connection
    ./bin/verify-dev.sh
    
  3. Plugin Issues

    # Resync plugins from production
    ./bin/sync-production.sh --plugins-only
    
    # Verify plugin status
    ./bin/verify-dev.sh --plugins
    

Debug Mode

# Enable WordPress debug mode
./bin/setup-dev.sh --debug

# View debug logs
tail -f wp-content/debug.log

Security Notes

  1. Never commit .env to version control
  2. Use WordPress Application Passwords for API access
  3. Keep production credentials secure
  4. Regularly rotate passwords and tokens
  5. Keep SSL certificates secure

Support

For issues:

  1. Check debug logs
  2. Review container logs
  3. Verify environment configuration
  4. Contact development team:

Last Updated: March 25, 2025