pixel_ninja
Expert Member
HI Guys,
I have configured a shell command file which dumps a list of banned websites into the bannedsitelist, and a second shell which clears the contents of that list.
Now all I have to do is schedule a cron job to run the enable.sh/disable.sh shell commands. here are the steps I followed:
cd /root
nano WEBFILTER
0 8 * * 1,2,3,4,5 /root/enable.sh >/dev/null 2>&1
0 10 * * 1,2,3,4,5 /root/disable.sh >/dev/null 2>&1
15 10 * * 1,2,3,4,5 /root/enable.sh >/dev/null 2>&1
0 13 * * 1,2,3,4,5 /root/disable.sh >/dev/null 2>&1
0 14 * * 1,2,3,4,5 /root/enable.sh >/dev/null 2>&1
30 16 * * 1,2,3,4,5 /root/disable.sh >/dev/null 2>&1
crontab WEBFILTER
I have manually run the enable.sh/disable.sh and it does block/unblock the sites, so I suspect that I have not configured the cron correctly.
Any advice would be great
I have configured a shell command file which dumps a list of banned websites into the bannedsitelist, and a second shell which clears the contents of that list.
Now all I have to do is schedule a cron job to run the enable.sh/disable.sh shell commands. here are the steps I followed:
cd /root
nano WEBFILTER
0 8 * * 1,2,3,4,5 /root/enable.sh >/dev/null 2>&1
0 10 * * 1,2,3,4,5 /root/disable.sh >/dev/null 2>&1
15 10 * * 1,2,3,4,5 /root/enable.sh >/dev/null 2>&1
0 13 * * 1,2,3,4,5 /root/disable.sh >/dev/null 2>&1
0 14 * * 1,2,3,4,5 /root/enable.sh >/dev/null 2>&1
30 16 * * 1,2,3,4,5 /root/disable.sh >/dev/null 2>&1
crontab WEBFILTER
I have manually run the enable.sh/disable.sh and it does block/unblock the sites, so I suspect that I have not configured the cron correctly.
Any advice would be great