Merge pull request #424 from TheSerapher/cronhome-detection
Adding CRONHOME detection to run-crons.sh
This commit is contained in:
commit
4b684ac45a
@ -12,9 +12,6 @@ PHP_BIN=$( which php )
|
||||
# Path to PID file, needs to be writable by user running this
|
||||
PIDFILE='/tmp/mmcfe-ng-cron.pid'
|
||||
|
||||
# Location of our cronjobs, assume current directory
|
||||
CRONHOME='.'
|
||||
|
||||
# List of cruns to execute
|
||||
CRONS="findblock.php proportional_payout.php pplns_payout.php pps_payout.php blockupdate.php auto_payout.php tickerupdate.php notifications.php statistics.php archive_cleanup.php"
|
||||
|
||||
@ -30,6 +27,9 @@ VERBOSE="0"
|
||||
# #
|
||||
################################################################
|
||||
|
||||
# Find scripts path
|
||||
CRONHOME=$( dirname $0 )
|
||||
|
||||
# Change working director to CRONHOME
|
||||
if ! cd $CRONHOME 2>/dev/null; then
|
||||
echo "Unable to change to working directory \$CRONHOME: $CRONHOME"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user