[Cialug] cron gpg

Jeffrey C. Ollie jeff at ocjtech.us
Mon Aug 28 10:52:02 CDT 2006


On Mon, 2006-08-28 at 10:48 -0500, Barry Von Ahsen wrote:
> I have a process that gpgs and ftps a file.  When I run it from the 
> command line (as root), everything works fine.  When cron tries to run 
> it (as root), it claims it can't find the gpg key it needs.  Is there 
> anything special I need to do?  Is cron really running as root, or as 
> some root-equivalent user?  This is on RHEL 4.3
>
> [...]
>
> Here is cron's env:
> [...]
> HOME=/
>
> [...]
> 
> Here is root's env (from the same dir):
> [...]
> HOME=/root

Try manually specifying the home directory by using gpg's "--homedir"
option.

Also, I'd recommend running the cron job as a non-root user, preferably
one setup specifically for the task,

Jeff

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://cialug.org/pipermail/cialug/attachments/20060828/1d257ecd/attachment.pgp


More information about the Cialug mailing list