[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [cobalt-users] Sending mail with attachment via cron?
- Subject: Re: [cobalt-users] Sending mail with attachment via cron?
- From: Gerald Waugh <gwaugh@xxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed May 28 15:25:01 2003
- List-id: Mailing list for users to share thoughts on Sun Cobalt products. <cobalt-users.list.cobalt.com>
On Wed, 28 May 2003, Ren[ISO-8859-1] é Mølsted wrote:
> Hi all
> I need to send a mail containing a file or contents of a text file via
> crontab. How is that done?
> Or is it possible to have PGP send a mail with the encrypted file?
cat file.text | mail -s "some subject" someone@xxxxxxxxxxxxxx
or
cat file.text | mail -s "some subject" admin
We do this is cron jobs all the time;
for instance to check CPu temp every 15 minutes;
(all on one line of course)
15 * * * * cat /proc/cpuinfo | grep temperature | mail -s "CPU
temperatue" admin
Gerald
--
http://frontstreetnetworks.com | http://store.raqware.com
Front Street Networks LLC, 229 Front Street, Ste.#C
New Haven, CT 06513-3203 | phone: +1-203-785-0699