Bash / CLI Joomla! 6 Joomla! 5 Joomla! 4 CLI Basic

Toggle Maintenance Mode (Offline) via CLI During Deployments

Puts Joomla offline, pulls updates, cleans cache and brings the site back live cleanly using site:down and site:up.

Updated on 24 November 2026 37 copies 129 views
scripts/deploy_maintenance.sh
# Coloca o site em manutenção
php cli/joomla.php site:down

# Atualiza o código via Git-First e limpa o cache
git pull origin master
php cli/joomla.php cache:clean

# Restaura o site online
php cli/joomla.php site:up
Super Users can still preview the site while offline mode is active.

Technical explanation and best practices

Native site:down and site:up commands safely toggle $offline in configuration.php during SSH maintenance or CI/CD deploys.

Direct Engineering

Have a Joomla project or technical challenge in mind?

From architectural diagnosis to production deployment, directly with the engineer.