Last active
August 25, 2018 10:03
-
-
Save armsp/5fb894464a1db2f8880063ffaa853af9 to your computer and use it in GitHub Desktop.
Dockerfile to install python, pandas, sklearn, numpy, scipy on a ubuntu 18.10 container (works under restricted ssl certificate environments too)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM ubuntu:18.10 | |
RUN apt-get update && apt-get upgrade -y \ | |
&& apt-get install -y --no-install-recommends apt-utils software-properties-common wget \ | |
&& apt-get install -y build-essential python3 python3-distutils \ | |
&& wget --no-check-certificate https://bootstrap.pypa.io/get-pip.py \ | |
&& python3 get-pip.py --trusted-host pypi.org --trusted-host files.pythonhosted.org | |
#RUN apt-get install python3.6 python-pip | |
#RUN python -m pip install pip --upgrade | |
#RUN python -m pip install wheel | |
#RUN apt-get install -y python3-numpy | |
ENV DEBIAN_FRONTEND noninteractive \ | |
&& DBCONF_NONINTERACTIVE_SEEN true | |
# Installing pandas will also install scipy and numpy. However the independent commands are similar i.e python3-numpy, python3-scipy | |
# To install sklearn follow the same pattern i.e python3-sklearn | |
RUN apt-get install -y python3-pandas \ | |
&& echo "Asia/Kolkata" > /etc/timezone \ | |
&& dpkg-reconfigure -f noninteractive tzdata | |
RUN mkdir /code | |
#COPY app.py /code | |
COPY requirements.txt /code | |
WORKDIR /code | |
RUN pip install --trusted-host pypi.org --trusted-host files.pythonhosted.org --no-cache-dir -r requirements.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
flask | |
flask-restful |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment