Add Dockerfile; fix predict.py and server.py

This commit is contained in:
python273 2016-11-17 07:33:15 +03:00
parent 557024d980
commit 3af4766358
No known key found for this signature in database
GPG Key ID: B8A168B3A02C01E3
174 changed files with 43 additions and 9 deletions

36
Dockerfile Normal file
View File

@ -0,0 +1,36 @@
FROM ubuntu:14.04
RUN apt-get update && apt-get install -y \
pkg-config \
libpng-dev \
libjpeg8-dev \
libfreetype6-dev \
libblas-dev \
liblapack-dev \
libatlas-base-dev \
gfortran \
python \
python-dev \
python-pip \
curl && \
curl -sL https://deb.nodesource.com/setup_7.x | sudo -E bash - && \
apt-get install -y nodejs
RUN npm install webpack --save-dev
RUN npm install webpack -g
RUN pip install -U https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.11.0rc2-cp27-none-linux_x86_64.whl && \
pip install magenta ipython
COPY ./server/requirements.txt /tmp/
RUN pip install -r /tmp/requirements.txt
COPY . /src/
WORKDIR /src/static/
RUN npm install && webpack -p
WORKDIR /src/server/
EXPOSE 8080
ENTRYPOINT python server.py

View File

Before

Width:  |  Height:  |  Size: 39 KiB

After

Width:  |  Height:  |  Size: 39 KiB

Some files were not shown because too many files have changed in this diff Show More