13 lines
420 B
Bash
Executable file
13 lines
420 B
Bash
Executable file
#!/bin/bash
|
|
# Reddit Media Collector - Daily Cron Script
|
|
|
|
cd /home/richard/reddit-media-collector
|
|
|
|
# Add local bin to PATH for yt-dlp
|
|
export PATH="$HOME/.local/bin:$PATH"
|
|
|
|
# Run collector with timeout (4 hours max)
|
|
timeout 4h python3 -m src.main >> /home/richard/reddit-media-collector/cron.log 2>&1
|
|
|
|
# Log completion
|
|
echo "$(date): Collector finished with exit code $?" >> /home/richard/reddit-media-collector/cron.log
|