From 0b40015045218bae20a978c3711b301f9728cf90 Mon Sep 17 00:00:00 2001 From: Youri Westerman Date: Mon, 18 Nov 2024 13:56:37 +0100 Subject: [PATCH] Download the nltk data during container image build --- Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index e6f8168..0973ffb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -32,10 +32,10 @@ CMD uwsgi FROM signals-classification-base AS signals-classification-train -RUN mkdir /tmp/nltk - -ENV NLTK_DATA /tmp/nltk +ENV NLTK_DATA /usr/local/share/nltk_data RUN poetry install --with train +RUN python -m nltk.downloader -d /usr/local/share/nltk_data stopwords + ENTRYPOINT ["python", "/app/app/train/run.py"]