-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Added container for python 3.7
- Loading branch information
Showing
3 changed files
with
43 additions
and
1 deletion.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
FROM debian:stable | ||
|
||
# ensure our python is preferred over distribution python | ||
ENV PATH /usr/local/bin:$PATH | ||
|
||
ENV LANG C.UTF-8 | ||
|
||
ENV PYTHON_VERSION 3.7.3 | ||
|
||
ENV PYTHON_PIP_VERSION 19.0.3 | ||
|
||
RUN apt-get update \ | ||
&& apt-get install build-essential checkinstall cmake git libreadline-gplv2-dev libncursesw5-dev libssl-dev \ | ||
libsqlite3-dev tk-dev libgdbm-dev libc6-dev libbz2-dev libffi-dev libprotobuf-dev libprotoc-dev protobuf-compiler wget -y | ||
|
||
RUN cd /usr/src \ | ||
&& wget https://www.python.org/ftp/python/$PYTHON_VERSION/Python-$PYTHON_VERSION.tgz \ | ||
&& tar xzf Python-$PYTHON_VERSION.tgz \ | ||
&& cd Python-$PYTHON_VERSION \ | ||
&& ./configure --enable-optimizations \ | ||
&& make altinstall | ||
|
||
RUN pip3 install --upgrade pip setuptools wheel | ||
|
||
RUN ln -s /usr/local/bin/python3.7 /usr/local/bin/python3 \ | ||
&& ln -s /usr/local/bin/pip3.7 /usr/local/bin/pip3 \ | ||
&& ln -s /usr/local/bin/python3.7 /usr/local/bin/python \ | ||
&& ln -s /usr/local/bin/pip3.7 /usr/local/bin/pip \ | ||
&& ln -s /usr/local/bin/pydoc3.7 /usr/local/bin/pydoc3 \ | ||
&& ln -s /usr/local/bin/python3.7m-config /usr/local/bin/python3-config \ | ||
&& ln -s /usr/local/bin/pydoc3.7 /usr/local/bin/pydoc \ | ||
&& ln -s /usr/local/bin/python3.7m-config /usr/local/bin/python-config | ||
|
||
RUN mkdir -p /usr/src/app | ||
WORKDIR /usr/src/app | ||
|
||
ONBUILD COPY requirements.txt . | ||
ONBUILD RUN pip3 install -r requirements.txt | ||
ONBUILD COPY . /usr/src/app | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# ml-debian-python/3.7 | ||
Base container for machine learning projects containing Python 3.7 environment. |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
# ml-debian-python | ||
Base container for machine learning projects. | ||
Base debian containers for machine learning projects. |