-
-
Notifications
You must be signed in to change notification settings - Fork 71
/
Dockerfile
56 lines (47 loc) · 1.76 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
ARG FROM=debian:bullseye
FROM ${FROM}
ENV DEBIAN_FRONTEND=noninteractive
ENV CRYPTOGRAPHY_DONT_BUILD_RUST=1
RUN apt-get update && apt-get install --no-install-recommends --yes \
build-essential \
curl \
file \
libffi-dev \
librabbitmq4 \
libssl-dev \
poppler-utils \
pst-utils \
python3-dateutil \
python3-dev \
python3-feedparser \
python3-lxml \
python3-pip \
python3-pycurl \
python3-pyinotify \
python3-pysolr \
python3-rdflib \
python3-requests \
python3-scrapy \
python3-setuptools \
python3-sparqlwrapper \
python3-wheel \
tesseract-ocr \
# tesseract-ocr-all \
&& apt-get clean -y && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
COPY ./src/opensemanticetl/requirements.txt /usr/lib/python3/dist-packages/opensemanticetl/requirements.txt
# install Python PIP dependecies
RUN pip3 install -r /usr/lib/python3/dist-packages/opensemanticetl/requirements.txt
COPY ./src/opensemanticetl /usr/lib/python3/dist-packages/opensemanticetl
COPY ./src/tesseract-ocr-cache/tesseract_cache /usr/lib/python3/dist-packages/tesseract_cache
COPY ./src/tesseract-ocr-cache/tesseract_fake /usr/lib/python3/dist-packages/tesseract_fake
COPY ./src/open-semantic-entity-search-api/src/entity_linking /usr/lib/python3/dist-packages/entity_linking
COPY ./src/open-semantic-entity-search-api/src/entity_manager /usr/lib/python3/dist-packages/entity_manager
COPY docker-entrypoint.sh /
RUN chmod 755 /docker-entrypoint.sh
# add user
RUN adduser --system --disabled-password opensemanticetl
RUN mkdir /var/cache/tesseract
RUN chown opensemanticetl /var/cache/tesseract
USER opensemanticetl
# start Open Semantic ETL celery workers (reading and executing ETL tasks from message queue)
CMD ["/docker-entrypoint.sh"]