-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ocrmypdf with incrontab / inotify #90
Comments
Hello, incrond behaves like cron and runs in a sparse environment.
|
EDIT: Solved it by changing the path in the script (see below). Incron is working in "/", and therefore is not able to create som temporary files... I just tried a similar thing with version 3.1 and ocrmypdf fails while opening a database :-( :
My script: #!/bin/bash
exec 1> >(logger -s -t $(basename $0)) 2>&1
cd /media/DatenExt/Scanner/out/
INFILE=${1##*/}
OUTFILE=${INFILE%.*}_ocr.pdf
/usr/local/bin/ocrmypdf -l deu $1 /media/DatenExt/Scanner/out/$OUTFILE I suppose it's something with the environment of incron, executing the script seperately works just fine. |
Yes, it needs to be create that file, so needs a writable CWD. I think. I The active project is now jbarlow83/ocrmypdf. Please record any other
|
Hi,
this is not realey an issue of ocrmypdf, but I'm trying to get this to work on an samba-share with incrontab /inotify.
I've created a folder and watch activities in this folder with incrontab. That works fine for things like pdftk, but nothing happens on ocrmypdf. Syslog shows the command correct, but then ends.
my incrontab -e$@/$ # $@/out/$ #$@/../$ #$@/$ # stamp $@/BB.pdf output $ @/out/$#$@/../$ #
/home/pdfin IN_CLOSE_WRITE /opt/ocrmypdf/ocrmypdf.sh
/home/pdfin/out IN_CLOSE_WRITE /bin/rm
->this works fine for stamping pdfs with logo
/home/stamp IN_CLOSE_WRITE /usr/bin/pdftk
/home/stamp/out IN_CLOSE_WRITE /bin/rm
Any ideas?
The text was updated successfully, but these errors were encountered: