Repository navigation
Version 2.2.0
Operations release: every core container now reports a health state, uploaded SVG is sandboxed, identical files under upload/ can be merged monthly, and the production pull wrapper validates nginx configuration on the right network.
Health checks
nginx,php,php-cronandmysqlcarry health checks indocker-compose.yml: nginx probes itsstub_statusvhost on port 8084, php opens a TCP connection to port 9000 (replacing the image'sphp --ini, which passed while php-fpm was down), php-cron looks for the cron daemon, mysql pings over its socket. Start order is unchanged; dependencies do not wait on health checks.- On hosts that already use the standard "Docker by Zabbix agent 2" template, it can alert on the new health states.
nginx
/upload/**.svgis served withContent-Security-Policy: default-src 'none'; style-src 'unsafe-inline'; sandbox, the policy bitrix-env ships for the same path, so script inside an uploaded SVG cannot run in the site origin when the file is opened as a document. The same policy disables other active or external content in such documents; a site that serves interactive SVG documents fromupload/needs to adjust the rule.- The scanner fast-404 list gains
.old,.saveand a trailing~.
Upload deduplication
scripts/dedup-upload.shreplaces byte-identical files underweb/prod/uploadwith hard links usinghardlinkfrom util-linux: owner, mode and extended attributes must match, only the modification time is ignored. The listed scratch, exchange and log directories of known modules are excluded, a lock keeps two dedup runs apart, and the fullhardlinkoutput with its exit status goes tologs/dedup-upload.log;--dry-runshows what a run would save.config/cron/host.cronruns it on the first of every month at 02:20 host time.
Fixes
scripts/pull-public.sh, this deployment's pull wrapper, validates a changed nginx file bind in a fresh container on php's network, so the php upstream resolves when nginx belongs to more than one network. Before, the test container joined the first network in nginx's list, the validation failed there and nginx was not restarted.
Upgrade notes
- Recreate
nginx,php,php-cronandmysqlafter pulling so the health checks attach; the mysql recreate restarts the database. - The deduplication needs
hardlinkfrom util-linux andflockon the host; the script exits with a message when either is missing. - Hard links share later in-place writes between the merged copies. Before enabling the monthly job, check which processes write under your
upload/and extend the excluded directories in the script accordingly; the lock only prevents a second dedup run, it does not hold off importers or the image optimiser.