Enhance the Seafile MySQL dump hook with better debugging capabilities
and systemd service compatibility:
- Redirect all output to syslog for systemd journal integration
- Add Docker socket accessibility check before attempting dumps
- Add detailed logging at each step for troubleshooting
- Improve error handling with explicit exit codes
- Add context information (USER, PWD, HOME) for systemd debugging
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Update the Seafile MySQL dump hook to use the root user by default
instead of seafile user, which resolves authentication issues. Add
SEAFILE_MYSQL_USER environment variable for user customization.
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Add comprehensive validation and error messages to the Seafile MySQL backup hook:
- Add timeout (5min) to prevent mysqldump from hanging indefinitely
- Validate SEAFILE_DB_PASSWORD is set before attempting dump
- Verify Docker container exists and is running before execution
- Fix file verification bug (check correct output filename)
- Add detailed logging for easier troubleshooting
- Use set -e for fail-fast behavior
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>