]> git.ipfire.org Git - thirdparty/paperless-ngx.git/commitdiff
Use correct canonical path for nltk_data
authoramo13 <amaury@mailbox.org>
Sat, 14 Jan 2023 14:37:27 +0000 (15:37 +0100)
committerTrenton H <797416+stumpylog@users.noreply.github.com>
Mon, 16 Jan 2023 22:20:42 +0000 (14:20 -0800)
Dockerfile
docs/configuration.md
src/paperless/settings.py

index b616c70e727d9870121d615a3e8ef6832e329c80..687d993c7550a5fa5439990b25618b6348547712 100644 (file)
@@ -234,9 +234,9 @@ RUN set -eux \
   && echo "Installing Python requirements" \
     && python3 -m pip install --default-timeout=1000 --no-cache-dir --requirement requirements.txt \
   && echo "Installing NLTK data" \
-    && python3 -W ignore::RuntimeWarning -m nltk.downloader -d "/usr/local/share/nltk_data" snowball_data \
-    && python3 -W ignore::RuntimeWarning -m nltk.downloader -d "/usr/local/share/nltk_data" stopwords \
-    && python3 -W ignore::RuntimeWarning -m nltk.downloader -d "/usr/local/share/nltk_data" punkt \
+    && python3 -W ignore::RuntimeWarning -m nltk.downloader -d "/usr/share/nltk_data" snowball_data \
+    && python3 -W ignore::RuntimeWarning -m nltk.downloader -d "/usr/share/nltk_data" stopwords \
+    && python3 -W ignore::RuntimeWarning -m nltk.downloader -d "/usr/share/nltk_data" punkt \
   && echo "Cleaning up image" \
     && apt-get -y purge ${BUILD_PACKAGES} \
     && apt-get -y autoremove --purge \
index 1b361f9aa6ab9ae2ce5a38491791b3dbe5fa1ad1..873db795ee333f401af166a2dc9594a52fbb1bdd 100644 (file)
@@ -179,7 +179,7 @@ Previously, the location defaulted to `PAPERLESS_DATA_DIR/nltk`.
 Unless you are using this in a bare metal install or other setup,
 this folder is no longer needed and can be removed manually.
 
-Defaults to `/usr/local/share/nltk_data`
+Defaults to `/usr/share/nltk_data`
 
 ## Logging
 
index 79a7a553b71298a12ab06f51ca0a2c2aab6adf89..c5bb4801c01b964e8608cec3ca5c81f9aa181644 100644 (file)
@@ -178,7 +178,7 @@ THUMBNAIL_DIR = os.path.join(MEDIA_ROOT, "documents", "thumbnails")
 
 DATA_DIR = __get_path("PAPERLESS_DATA_DIR", os.path.join(BASE_DIR, "..", "data"))
 
-NLTK_DIR = __get_path("PAPERLESS_NLTK_DIR", "/usr/local/share/nltk_data")
+NLTK_DIR = __get_path("PAPERLESS_NLTK_DIR", "/usr/share/nltk_data")
 
 TRASH_DIR = os.getenv("PAPERLESS_TRASH_DIR")