Improved

Deploys roll back only when a page fails the check

A self-check failure, such as a folder the web server cannot write to, is emailed and leaves the release live; only a page that fails rolls the deploy back. The self-check also covers the repositories folder.

The deploy check rolled back on any failure, although a folder the web server cannot write to or a database that does not answer is a problem on the server that the previous release shares. bin/deploy-check.php now exits 3 for such a failure, and deployment/deploy.sh reports it, emails ERROR_ALERT_EMAIL, and keeps the release live; only exit 1, a page that fails, rolls back with DEPLOY_CHECK_ROLLBACK=1. The self-check at /deploy-check also tries the repositories folder, REPOSITORY_STORAGE_ROOT, which lives outside the release and which nothing else checks.