feat: Migrate to system-specific crontab files with enhanced logging and management

This commit is contained in:
Peter Wood
2025-05-26 12:10:15 -04:00
parent b016f4e241
commit e6aec6dd5d
9 changed files with 70 additions and 44 deletions

View File

@@ -334,3 +334,64 @@ Note that these commands will run as `root`.
```shell
./shell/plex.sh {start|stop|restart|status}
```
## Enhanced Crontab System Migration
### System Status
The crontab system has been migrated from a universal `crontab.txt` to system-specific files:
- **crontab-europa.txt** - Media server configuration
- **crontab-io.txt** - Download/acquisition server configuration
- **crontab-racknerd.txt** - Backup server configuration
### Legacy File Status
The original `crontab.txt` has been:
- **Backed up** to `crontab.txt.bak`
- **Role**: Previously served as fallback, now obsolete
- **Content**: Contains mixed configuration that was split into system-specific files
### Current Management
Use the system-specific approach:
```bash
# Install system-specific crontab
./manage-enhanced-crontab.sh install
# The script automatically detects hostname and uses appropriate file
# europa -> crontab-europa.txt
# io -> crontab-io.txt
# racknerd -> crontab-racknerd.txt
```
### Fallback Behavior
If a system-specific file is missing, the management script will:
1. **Warning**: Display that system-specific file is not found
2. **Recommendation**: Create appropriate system-specific file
### Creating New System Files
For new systems, create system-specific files based on the templates:
```bash
# Copy and customize for new system
cp crontab-europa.txt crontab-newsystem.txt
# Edit for system-specific tasks
```
### Benefits of System-Specific Approach
- **Clear separation** of concerns between systems
- **Reduced conflicts** from universal configurations
- **System-appropriate** task scheduling
- **Better maintenance** and troubleshooting
- **Scalable** for additional systems
#### Migration Notes
Migration completed: May 26, 2025