This page describes the setup of an independent OCR appliance for use with the Extended DMS environment. DMS will access the OCR appliance and issue commands so that OCR is performed. The advantages are that the DMS appliance's resources (CPU, RAM) are thus not consumed by the OCR processing. Given its advantages, the below instructions describe the setup of a dockerized OCR engine in a separate VM.
/<storagepath>/nuxeo/data/
and /<storagepath>/nuxeo/tmp/
NFS-exports /var/lib/nuxeo/data/
and /opt/nuxeo/server/tmp/
respectively and make sure these mounts will be auto mounted (kept alive)/<storagepath>/nuxeo/scripts/
and make executable (chmod +x). This script contains the commands to drive the OCR process for each file.<<adminuserhome>>/.ssh/authorized_keys
file of OCR appliance~/.ssh/
to /<storagepath>/nuxeo/ssh/
~/deploy/config/
)#!/bin/bash echo "variables $1 $2" ssh <<adminuser>>@<<ocr.appliance.name>> "docker run -v /var/lib/nuxeo/data/:/var/lib/nuxeo/data -v /opt/nuxeo/server/tmp/:/opt/nuxeo/server/tmp/ --rm practiceinsight/dms_tesseract:1.0 $1 $2" |
$1 is the path and filename of the output file, $2 is the path and filename of the input file that are handed over when the DMS calls the tesseract script. The command in tesseract script must be such that the OCR engine reads the input file (pointed to by $2) and writes to the output file (pointed to by $2).
Make sure you replace <<adminuser>> with correct user name of an administrative user in OCR appliance, and <<ocr.appliance.name>> with proper FQND or IP address.
"elif [ ${1} = "NUXEO" ] then"
) so as to be added the container run command.:add_volume "/<storage_path>/nuxeo/ssh" "/home/nuxeo/.ssh" add_volume "/<storage_path>/nuxeo/scripts/tesseract" "/usr/local/bin/tesseract" |