HylaFAX The world's most advanced open source fax server

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [hylafax-users] External script howto?



DON HARPELL wrote:

Thanks for the reply. I am trying to run a script to upload the fax to a docushare server. It fails because of the chroot enviroment. I was trying to run it from faxrcvd. I would like it to run after the fax is received.

I've done something similar here. I mounted the remote SMB share on the Hylafax server with UID and GID options set to the uucp user/group so the Hylafax process would have the ability to write to the location. Then rather than modifying the faxrcvd file, I put the logic inside the FaxDispatch file. The variables set withing faxrcvd are available within FaxDispatch when it's sourced. This way I avoided changing the provided scripts and won't need to worry about my customization being lost during an upgrade.


The variable $FILE seems to contain a reference to the received fax's file name with the recq folder included. This appears to be the relative path necessary for referencing the file at the time FaxDispatch is sourced. Also $FILENAME contains just the base file name without the directory or extension. With these two I was able to put the file on the network share with a command like the following:

cp $FILE $DESTPATH/$FILENAME.tiff

Hope this helps.

--
Jamin W. Collins

____________________ HylaFAX(tm) Users Mailing List _______________________
 To subscribe/unsubscribe, click http://lists.hylafax.org/cgi-bin/lsg2.cgi
On UNIX: mail -s unsubscribe hylafax-users-request@xxxxxxxxxxx < /dev/null
 *To learn about commercial HylaFAX(tm) support, mail sales@xxxxxxxxx*




Project hosted by iFAX Solutions