Chapter 11: Application Hosting — WordPress, Flask and Express
Common Mistakes I See Students Make
- Installing WordPress before attaching an Elastic IP — the site breaks after stop/start.
- Wrong ownership of WordPress files (not
www-data/apache) → plugins and uploads fail. - Forgetting
AllowOverride All/a2enmod rewrite→ permalinks give 404. - Skipping the security salts in
wp-config.php. - Running Flask with
app.run(debug=True)in production — debug mode can allow remote code execution. - Wrong module path in Gunicorn (
app:appvswsgi:app) → ModuleNotFoundError injournalctl. - Not running the command printed by
pm2 startup, so apps don't come back after reboot.