forked from luistovar/sara
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
49 lines (42 loc) · 1 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
# SARA
# https://github.com/mxabierto/sara
# Build:
# docker build -t mxabierto/sara .
# Usage:
# docker run \
# --name sara \
# --link sara-mysql:mysql \
# --link sara-es:elasticsearch \
# --link sara-redis:redis \
# -v `pwd`/logs:/logs \
# -e SARA_MODEL="..." \
# -e PETITIONS_SERVER_URL="x.x.x.x" \
# -p 5000:5000 \
# -d mxabierto/sara
# Base image
FROM mxabierto/jessie
MAINTAINER iorch <[email protected]>
# Install dependencies
RUN \
apt-get update && \
apt-get install -y \
python-dev \
python-pip \
liblapack-dev \
libopenblas-dev \
libxml2-dev \
python-scipy \
libmysqlclient-dev \
libxslt1-dev && \
ldconfig && \
rm -rf /var/lib/apt/lists/*
# Add source
ADD requirements.txt /root/sara/requirements.txt
RUN cd /root/sara && \
pip install --upgrade pip && \
pip install --force-reinstall --ignore-installed --upgrade -r requirements.txt
ADD . /root/sara/
# Default port
EXPOSE 5000
# Start the classifier service by default
CMD ["/root/sara/start.sh"]