Re: Auto dist-upgrade script
On Thu, 2002-09-05 at 23:53, ThanhVu Nguyen wrote:
> Hi, I've heard people can write some scripts and put it in a cron job
> that do a dist-upgrade on their system then send what've been upgraded
> to their emails. Can someone share how they did it ? thanks
This is my crontab to do nightly mantinence on my system(backups to be
added as soon as I get my new server up and running :-D)
# use /bin/sh to run commands, no matter what /etc/passwd says
SHELL=/bin/sh
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/bin/X11:/usr/local/sbin:/usr/local/bin
# mail any output to `admin'
MAILTO=admin@example.com
30 4 * * * dselect update && apt-get dist-upgrade -ydu &&
apt-history; ntpdate ns1.yourISP.com
--
Reply to: