diff --git a/OCR/Dockerfile b/OCR/Dockerfile index 3c9329aa..68787a90 100644 --- a/OCR/Dockerfile +++ b/OCR/Dockerfile @@ -4,7 +4,7 @@ RUN apt-get update && apt-get install libgl1 tesseract-ocr-eng tesseract-ocr -y # Use larger "best" training data, rather than "fast" # Python one-liner because we don't have curl or wget -RUN python3 -c 'from urllib.request import urlopen; print(urlopen("https://github.com/tesseract-ocr/tessdata_best/raw/refs/heads/main/eng.traineddata").read())' > /usr/share/tesseract-ocr/5/tessdata/eng.traineddata +RUN python3 -c 'from urllib.request import urlopen; open("/usr/share/tesseract-ocr/5/tessdata/eng.traineddata", "wb").write(urlopen("https://github.com/tesseract-ocr/tessdata_best/raw/refs/heads/main/eng.traineddata").read())' RUN pip install poetry diff --git a/OCR/dev-dockerfile b/OCR/dev-dockerfile index 3a435867..d2e02d6b 100644 --- a/OCR/dev-dockerfile +++ b/OCR/dev-dockerfile @@ -4,7 +4,7 @@ RUN apt-get update && apt-get install libgl1 tesseract-ocr-eng tesseract-ocr -y # Use larger "best" training data, rather than "fast" # Python one-liner because we don't have curl or wget -RUN python3 -c 'from urllib.request import urlopen; print(urlopen("https://github.com/tesseract-ocr/tessdata_best/raw/refs/heads/main/eng.traineddata").read())' > /usr/share/tesseract-ocr/5/tessdata/eng.traineddata +RUN python3 -c 'from urllib.request import urlopen; open("/usr/share/tesseract-ocr/5/tessdata/eng.traineddata", "wb").write(urlopen("https://github.com/tesseract-ocr/tessdata_best/raw/refs/heads/main/eng.traineddata").read())' RUN pip install poetry