-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaiworker.dockerfile
58 lines (46 loc) · 1.77 KB
/
aiworker.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
57
58
FROM python:3.7.4-alpine3.10
MAINTAINER [email protected]
RUN cat /etc/apk/repositories
# RUN echo "http://mirrors.ustc.edu.cn/alpine/v3.10/main/">/etc/apk/repositories
# RUN echo "http://mirrors.ustc.edu.cn/alpine/v3.10/community">>/etc/apk/repositories
# RUN echo "http://mirrors.ustc.edu.cn/alpine/edge/testing/">>/etc/apk/repositories
RUN echo "http://dl-3.alpinelinux.org/alpine/v3.10/community">>/etc/apk/repositories
RUN echo "http://dl-3.alpinelinux.org/alpine/edge/testing/">>/etc/apk/repositories
RUN apk update
RUN apk add make automake gcc g++ subversion python3-dev
# RUN apk add py3-pandas
# RUN apk add py3-numpy
# RUN apk add py3-lxml
# RUN apk add py3-matplotlib
# RUN apk add py3-scikit-learn
# RUN /opt/conda/bin/conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
# RUN /opt/conda/bin/conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/
# RUN /opt/conda/bin/conda config --set show_channel_urls yes
# RUN mkdir ~/.pip
# RUN echo "[global]">~/.pip/pip.conf
# RUN echo "index-url = https://pypi.tuna.tsinghua.edu.cn/simple">>~/.pip/pip.conf
RUN pip install --upgrade pip
RUN pip install pandas
RUN pip install numpy
RUN apk add -q --progress libxml2-dev libxslt-dev libffi-dev
RUN pip install lxml
RUN pip install tushare
RUN pip install redis
RUN pip install threadpool
RUN apk add lapack lapack-dev gfortran
RUN pip install statsmodels
RUN apk add freetype-dev
RUN pip install matplotlib
RUN apk add cython
RUN pip install Cython
RUN pip install sklearn
# COPY $PWD /worker
WORKDIR /worker
# RUN ls
# RUN python getdailystocks.py
RUN python -c "import pandas"
RUN python -c "import numpy"
RUN python -c "import tushare"
RUN python -c "import statsmodels"
RUN python -c "import matplotlib"
RUN python -c "import sklearn"