Commit
·
ad2ce19
1
Parent(s):
53c2b9d
bug squashing
Browse files- Dockerfile +12 -7
Dockerfile
CHANGED
@@ -20,22 +20,27 @@ RUN git clone https://github.com/NeotomaDB/MetaExtractor.git
|
|
20 |
# inspired from: https://stackoverflow.com/questions/27713362/editing-files-from-dockerfile
|
21 |
# comment out file handle line due to file creation permission issues
|
22 |
RUN sed -i "s|port=8050|port=7860 |g" ./MetaExtractor/src/data_review_tool/app.py \
|
23 |
-
&& sed -i "s|logger.addHandler(get_file_handler())|#logger.addHandler(get_file_handler())|g" ./MetaExtractor/src/logs.py
|
|
|
|
|
|
|
|
|
|
|
24 |
|
25 |
-
# change ownership of the app folder to user
|
26 |
-
RUN chown -R root:user ./MetaExtractor/
|
|
|
27 |
|
28 |
# Copy the requirements.txt file to the working directory
|
29 |
# COPY ./requirements.txt .
|
30 |
|
31 |
-
# Install the Python dependencies
|
32 |
-
RUN pip install
|
33 |
|
34 |
WORKDIR MetaExtractor/
|
35 |
|
36 |
ENV LOG_LEVEL=DEBUG
|
37 |
|
38 |
-
|
39 |
EXPOSE 7860
|
40 |
|
41 |
RUN pip install pyarrow
|
@@ -43,7 +48,7 @@ RUN pip install pyarrow
|
|
43 |
RUN mkdir -p ./inputs
|
44 |
|
45 |
# set defualt env variables to sample files in the repo
|
46 |
-
ENV ARTICLE_RELEVANCE_BATCH=
|
47 |
ENV ENTITY_EXTRACTION_BATCH=entity-extraction-output.zip
|
48 |
|
49 |
# instead of vlume mapping copy sample files to expected input folder in regular image
|
|
|
20 |
# inspired from: https://stackoverflow.com/questions/27713362/editing-files-from-dockerfile
|
21 |
# comment out file handle line due to file creation permission issues
|
22 |
RUN sed -i "s|port=8050|port=7860 |g" ./MetaExtractor/src/data_review_tool/app.py \
|
23 |
+
&& sed -i "s|logger.addHandler(get_file_handler())|#logger.addHandler(get_file_handler())|g" ./MetaExtractor/src/logs.py \
|
24 |
+
&& sed -i 's|/entity_extraction|./entity_extraction|g' ./MetaExtractor/src/data_review_tool/app.py \
|
25 |
+
&& sed -i 's|/entity_extraction|./entity_extraction|g' ./MetaExtractor/src/data_review_tool/pages/home.py \
|
26 |
+
&& sed -i 's|/entity_extraction|./entity_extraction|g' ./MetaExtractor/src/data_review_tool/pages/article_review.py \
|
27 |
+
&& sed -i "s|/MetaExtractor/inputs/|./inputs/|g" ./MetaExtractor/src/data_review_tool/app.py \
|
28 |
+
&& sed -i 's|debug=True|debug=False|g' ./MetaExtractor/src/data_review_tool/app.py
|
29 |
|
30 |
+
# change ownership of the app folder to user & enable read/write/exectue permissions
|
31 |
+
RUN chown -R root:user ./MetaExtractor/ \
|
32 |
+
&& chmod -R 775 ./MetaExtractor/
|
33 |
|
34 |
# Copy the requirements.txt file to the working directory
|
35 |
# COPY ./requirements.txt .
|
36 |
|
37 |
+
# Install the Python dependencies, removed --no-cache-dir
|
38 |
+
RUN pip install -r MetaExtractor/docker/data-review-tool/requirements.txt
|
39 |
|
40 |
WORKDIR MetaExtractor/
|
41 |
|
42 |
ENV LOG_LEVEL=DEBUG
|
43 |
|
|
|
44 |
EXPOSE 7860
|
45 |
|
46 |
RUN pip install pyarrow
|
|
|
48 |
RUN mkdir -p ./inputs
|
49 |
|
50 |
# set defualt env variables to sample files in the repo
|
51 |
+
ENV ARTICLE_RELEVANCE_BATCH=apparticle-relevance-output.parquet
|
52 |
ENV ENTITY_EXTRACTION_BATCH=entity-extraction-output.zip
|
53 |
|
54 |
# instead of vlume mapping copy sample files to expected input folder in regular image
|