|
1 |
| -FROM ubuntu:18.04 |
| 1 | +FROM oraclelinux:7-slim |
2 | 2 |
|
3 | 3 | ARG release=19
|
4 | 4 | ARG update=9
|
5 | 5 |
|
| 6 | +RUN yum -y install oracle-release-el7 && \ |
| 7 | + yum-config-manager --enable ol7_oracle_instantclient && \ |
| 8 | + yum -y install oracle-instantclient${release}.${update}-basiclite && \ |
| 9 | + yum install -y oracle-epel-release-el7 |
| 10 | + |
6 | 11 | WORKDIR /app
|
7 | 12 | COPY foodwinepairing/requirements.txt .
|
8 | 13 |
|
9 |
| -# Update apt packages |
10 |
| -RUN apt update |
11 |
| -RUN apt upgrade -y |
12 |
| - |
13 |
| -# Install python 3.7 |
14 |
| -RUN apt install software-properties-common -y |
15 |
| -RUN add-apt-repository ppa:deadsnakes/ppa |
16 |
| -RUN apt install python3.7 -y |
17 |
| - |
18 |
| -# Make python 3.7 the default |
19 |
| -RUN echo "alias python=python3.7" >> ~/.bashrc |
20 |
| -RUN export PATH=${PATH}:/usr/bin/python3.7 |
21 |
| -RUN /bin/bash -c "source ~/.bashrc" |
22 |
| - |
23 |
| -# Add 3.7 to the available alternatives |
24 |
| -RUN update-alternatives --install /usr/bin/python python /usr/bin/python3.7 1 |
25 |
| - |
26 |
| -# Set python3.7 as the default python |
27 |
| -RUN update-alternatives --set python /usr/bin/python3.7 |
28 |
| - |
29 |
| -# Install pip |
30 |
| -RUN apt install python3-pip -y |
31 |
| -RUN python -m pip install --upgrade pip |
| 14 | +RUN yum install -y tar && \ |
| 15 | + yum install -y python36 && \ |
| 16 | + rm -rf /var/cache/yum && \ |
| 17 | + python3.6 -m pip install -U pip setuptools |
32 | 18 |
|
33 | 19 | #wine-pairing dependencies
|
34 |
| -RUN python -m pip install -U gensim |
35 |
| -RUN python -m pip install -U scikit-learn |
36 |
| -RUN python -m pip install -U pandas |
37 |
| -RUN python -m pip install -U numpy |
38 |
| -RUN python -m pip install -U nltk |
39 |
| -RUN python -m pip install -U matplotlib |
40 |
| -RUN python -m pip install -U ipython |
41 |
| -RUN python -m pip install -r requirements.txt |
| 20 | +RUN python3.6 -m pip install -U gensim && \ |
| 21 | + python3.6 -m pip install -U scikit-learn && \ |
| 22 | + python3.6 -m pip install -U pandas && \ |
| 23 | + python3.6 -m pip install -U nltk && \ |
| 24 | + python3.6 -m pip install -U matplotlib && \ |
| 25 | + python3.6 -m pip install -U ipython && \ |
| 26 | + python3.6 -m pip install -r requirements.txt |
42 | 27 |
|
43 | 28 | #to locate if/where gunicorn is
|
44 | 29 | RUN find / -name "gunicorn"
|
|
0 commit comments