mirror of
https://github.com/wekan/wekan.git
synced 2026-11-24 09:59:47 -05:00
The result of an Admin Panel backup lived only in the memory of the server process that ran it. After a restart, or on another pod of a multi-pod deployment, the Backup pane said "idle", so nobody could see whether last night's backup had worked. There was no history, no warning when a scheduled backup failed or did not run, and local backups were never cleaned up. - Every run, scheduled or "Backup now", is recorded in backupRuns: start and end, who or the schedule, scope, storage, status, size, duration and error. Records are kept 400 days. A run still "running" after 24 hours counts as failed, and a scheduled run skipped for another backup is recorded as failed. - Admin Panel / Problems / Backup shows the last success (overdue when its period has passed), the last failure with its error, the next run and the last 30 runs. The same status is above the schedule in Attachments / Backup. - Problems / Summary lists "Backup failed" and "Backup overdue". /metrics adds wekan_backup_last_success_timestamp_seconds, wekan_backup_last_run_timestamp_seconds, wekan_backup_last_run_success and wekan_backup_overdue for alerting. - BACKUP_KEEP_DAYS: after a successful backup, local backups of the same scope older than N days are deleted. The newest is always kept, and only a directory inside the backup root holding a backup.zip is removed. From the patch by Raymond-Voogt, and in Admin Panel as well: - BACKUP_KEEP_DAYS is the catalog's backup section (models/lib/authConfigCatalog.js), overridable beside the schedule in Admin Panel / Attachments / Backup and resolved through authEnv at every backup. - It is listed on every platform: the compose files, start-wekan.sh and .bat, the snap config and help, and the Dockerfile, which the patch's version had missed. Its platform hunks, written before #6789, were re-applied by hand. tests/backupRuns.test.cjs (21): the run records, overdue and pruning against a real directory, and the Admin Panel override, including that nothing reads the variable around it. tests/authConfigCatalog.test.cjs checks every platform. admin-attachment-retention.e2e.js checks the Backup pane shows the field. Thanks to Raymond-Voogt and xet7 ! Fixes #6790.
1.1 KiB
1.1 KiB
1) Matomo
https://github.com/wekan/wekan-snap/wiki/Supported-settings-keys#matomo-web-analytics-integration
2) Metrics
- Original PR. Thanks to Emile840.
- Fix typos and translate comments to English. Thanks to xet7.
- Added METRICS_ALLOWED_IP_ADDRESSES settings to Docker/Snap/Source and missing Matomo settings to Snap help. Thanks to xet7.
Docker
- METRICS_ALLOWED_IP_ADDRESSES=192.168.0.100,192.168.0.200
Backup metrics
The Admin Panel backup (docs/Backup/Backup.md) adds:
wekan_backup_last_success_timestamp_seconds # Unix time, 0 = never
wekan_backup_last_run_timestamp_seconds
wekan_backup_last_run_success # 1 or 0
wekan_backup_overdue # 1 when a scheduled backup is missing
Alert example: time() - wekan_backup_last_success_timestamp_seconds > 26*3600.