driesm
Developer
I'd like to define some local variables in a cron entry so that I can create the following file /usr/local/etc/cron.d/rsync with the following contents:
Will this work for the "excludes" and "backupdir" variable or can only environmental variables be set this way?
Code:
PATH=/etc:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin
excludes="--exclude=/storage --exclude=/proc"
backupdir="/storage/vados"
#minute hour mday month wday user command
0 * * * * root rsync -a $excludes / $backupdir --delete
Will this work for the "excludes" and "backupdir" variable or can only environmental variables be set this way?