I'm working on a project where I email a video to a special email address, and the attached video is saved in a web-accessible folder and re-encoded as Flash video.
The script works great up until the re-encoding. Essentially I have a procmail recipe that sends the email to a PHP script in ~/email. The video is saved, and then a command-line call to /usr/bin/ffmpeg is made using exec(), but I get this:
sh: line 1: /usr/bin/ffmpeg: No such file or directory
Now, the exec('ffmpeg...') call works perfectly when I run it from mydomain.com/script.php, so the difference must be that it's being called by the procmail recipe? Is it for some reason being run on a different server that doesn't have ffmpeg installed? If so, how can I point it back to the server that does have ffmpeg?
Thanks for your help!