kopia lustrzana https://github.com/nytimes/rd-blender-docker
Add containers for 2.93 and allow custom python versions
rodzic
b2a4c214a1
commit
c1b5317baa
|
@ -25,7 +25,9 @@ script:
|
|||
- if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then docker push nytimes/blender:2.91-gpu-ubuntu18.04; fi
|
||||
- if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then docker push nytimes/blender:2.92-cpu-ubuntu18.04; fi
|
||||
- if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then docker push nytimes/blender:2.92-gpu-ubuntu18.04; fi
|
||||
- if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then docker tag nytimes/blender:2.92-gpu-ubuntu18.04 nytimes/blender:latest; fi
|
||||
- if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then docker push nytimes/blender:2.93-cpu-ubuntu18.04; fi
|
||||
- if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then docker push nytimes/blender:2.93-gpu-ubuntu18.04; fi
|
||||
- if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then docker tag nytimes/blender:2.93-gpu-ubuntu18.04 nytimes/blender:latest; fi
|
||||
- if [[ $TRAVIS_PULL_REQUEST == 'false' ]]; then docker push nytimes/blender:latest; fi
|
||||
after_success:
|
||||
- bash ./notify.sh
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM ubuntu:18.04
|
||||
|
@ -44,7 +44,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM nvidia/cudagl:10.1-base-ubuntu18.04
|
||||
|
@ -44,7 +44,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM ubuntu:18.04
|
||||
|
@ -44,7 +44,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM nvidia/cudagl:10.1-base-ubuntu18.04
|
||||
|
@ -44,7 +44,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM ubuntu:18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM nvidia/cudagl:10.1-base-ubuntu18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM ubuntu:18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM nvidia/cudagl:10.1-base-ubuntu18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM ubuntu:18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM nvidia/cudagl:10.1-base-ubuntu18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM ubuntu:18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM nvidia/cudagl:10.1-base-ubuntu18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM ubuntu:18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# Dockerfile autogenerated on 02/25/2021, 16:04:39 by juniorxsound
|
||||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM nvidia/cudagl:10.1-base-ubuntu18.04
|
||||
|
@ -45,7 +45,7 @@ RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \
|
|||
&& rm -rf Python-3.7.0
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7m/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
|
|
@ -0,0 +1,54 @@
|
|||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM ubuntu:18.04
|
||||
|
||||
LABEL Author="Or Fleisher <or.fleisher@nytimes.com>"
|
||||
LABEL Title="Blender in Docker"
|
||||
|
||||
# Enviorment variables
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
ENV LC_ALL C.UTF-8
|
||||
ENV LANG C.UTF-8
|
||||
ENV PATH "$PATH:/bin/2.93/python/bin/"
|
||||
ENV BLENDER_PATH "/bin/2.93"
|
||||
ENV BLENDERPIP "/bin/2.93/python/bin/pip3"
|
||||
ENV BLENDERPY "/bin/2.93/python/bin/python3.9"
|
||||
ENV HW="CPU"
|
||||
|
||||
# Install dependencies
|
||||
RUN apt-get update && apt-get install -y \
|
||||
wget \
|
||||
libopenexr-dev \
|
||||
bzip2 \
|
||||
build-essential \
|
||||
zlib1g-dev \
|
||||
libxmu-dev \
|
||||
libxi-dev \
|
||||
libxxf86vm-dev \
|
||||
libfontconfig1 \
|
||||
libxrender1 \
|
||||
libgl1-mesa-glx \
|
||||
xz-utils
|
||||
|
||||
# Download and install Blender
|
||||
RUN wget https://mirror.clarkson.edu/blender/release/Blender2.93/blender-2.93.0-linux-x64.tar.xz \
|
||||
&& tar -xvf blender-2.93.0-linux-x64.tar.xz --strip-components=1 -C /bin \
|
||||
&& rm -rf blender-2.93.0-linux-x64.tar.xz \
|
||||
&& rm -rf blender-2.93.0-linux-x64
|
||||
|
||||
# Download the Python source since it is not bundled with Blender
|
||||
RUN wget https://www.python.org/ftp/python/3.9.1/Python-3.9.1.tgz \
|
||||
&& tar -xzf Python-3.9.1.tgz \
|
||||
&& cp -r Python-3.9.1/Include/* $BLENDER_PATH/python/include/python3.9/ \
|
||||
&& rm -rf Python-3.9.1.tgz \
|
||||
&& rm -rf Python-3.9.1
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib/python3.9/site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
||||
# Set the working directory
|
||||
WORKDIR /
|
|
@ -0,0 +1,54 @@
|
|||
# Dockerfile autogenerated on 06/09/2021, 09:43:33 by juniorxsound
|
||||
# Please do not edit this file directly
|
||||
|
||||
FROM nvidia/cudagl:10.1-base-ubuntu18.04
|
||||
|
||||
LABEL Author="Or Fleisher <or.fleisher@nytimes.com>"
|
||||
LABEL Title="Blender in Docker"
|
||||
|
||||
# Enviorment variables
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
ENV LC_ALL C.UTF-8
|
||||
ENV LANG C.UTF-8
|
||||
ENV PATH "$PATH:/bin/2.93/python/bin/"
|
||||
ENV BLENDER_PATH "/bin/2.93"
|
||||
ENV BLENDERPIP "/bin/2.93/python/bin/pip3"
|
||||
ENV BLENDERPY "/bin/2.93/python/bin/python3.9"
|
||||
ENV HW="GPU"
|
||||
|
||||
# Install dependencies
|
||||
RUN apt-get update && apt-get install -y \
|
||||
wget \
|
||||
libopenexr-dev \
|
||||
bzip2 \
|
||||
build-essential \
|
||||
zlib1g-dev \
|
||||
libxmu-dev \
|
||||
libxi-dev \
|
||||
libxxf86vm-dev \
|
||||
libfontconfig1 \
|
||||
libxrender1 \
|
||||
libgl1-mesa-glx \
|
||||
xz-utils
|
||||
|
||||
# Download and install Blender
|
||||
RUN wget https://mirror.clarkson.edu/blender/release/Blender2.93/blender-2.93.0-linux-x64.tar.xz \
|
||||
&& tar -xvf blender-2.93.0-linux-x64.tar.xz --strip-components=1 -C /bin \
|
||||
&& rm -rf blender-2.93.0-linux-x64.tar.xz \
|
||||
&& rm -rf blender-2.93.0-linux-x64
|
||||
|
||||
# Download the Python source since it is not bundled with Blender
|
||||
RUN wget https://www.python.org/ftp/python/3.9.1/Python-3.9.1.tgz \
|
||||
&& tar -xzf Python-3.9.1.tgz \
|
||||
&& cp -r Python-3.9.1/Include/* $BLENDER_PATH/python/include// \
|
||||
&& rm -rf Python-3.9.1.tgz \
|
||||
&& rm -rf Python-3.9.1
|
||||
|
||||
# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one
|
||||
RUN rm -rf ${BLENDER_PATH}/python/lib//site-packages/numpy
|
||||
|
||||
# Must first ensurepip to install Blender pip3 and then new numpy
|
||||
RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy
|
||||
|
||||
# Set the working directory
|
||||
WORKDIR /
|
27
generate.py
27
generate.py
|
@ -38,6 +38,8 @@ def create_dockerfile(base_os: str,
|
|||
env: list,
|
||||
deps: list,
|
||||
blender_download_url: str,
|
||||
python_download_url: str,
|
||||
python_version: str,
|
||||
workdir: str) -> str:
|
||||
"""
|
||||
Create a stringified Dockerfile based on arguments provided
|
||||
|
@ -60,7 +62,7 @@ def create_dockerfile(base_os: str,
|
|||
|
||||
archivetype = blender_download_url.split(".")[-1]
|
||||
archiveflags = "xjvf"
|
||||
|
||||
|
||||
if archivetype == "xz":
|
||||
archiveflags = "xvf"
|
||||
deps.append("xz-utils")
|
||||
|
@ -68,7 +70,7 @@ def create_dockerfile(base_os: str,
|
|||
for dependency, has_more in lookahead(deps):
|
||||
is_multiline = " \ " if has_more else ""
|
||||
dockerfile += "\u0009{}{}\n".format(dependency, is_multiline)
|
||||
|
||||
|
||||
# Needed so xz-utils doesn't accumalate
|
||||
if archivetype == "xz":
|
||||
deps.pop()
|
||||
|
@ -85,14 +87,21 @@ def create_dockerfile(base_os: str,
|
|||
blender_download_url.split("/")[-1].split(".tar."+archivetype)[0])
|
||||
|
||||
dockerfile += "# Download the Python source since it is not bundled with Blender\n"
|
||||
dockerfile += "RUN wget https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz \ \n"
|
||||
dockerfile += "\u0009&& tar -xzf Python-3.7.0.tgz \ \n"
|
||||
dockerfile += "\u0009&& cp -r Python-3.7.0/Include/* $BLENDER_PATH/python/include/python3.7m/ \ \n"
|
||||
dockerfile += "\u0009&& rm -rf Python-3.7.0.tgz \ \n"
|
||||
dockerfile += "\u0009&& rm -rf Python-3.7.0 \n\n"
|
||||
dockerfile += "RUN wget {} \ \n".format(python_download_url)
|
||||
dockerfile += "\u0009&& tar -xzf {} \ \n".format(
|
||||
python_download_url.split("/")[-1])
|
||||
dockerfile += "\u0009&& cp -r {}/Include/* $BLENDER_PATH/python/include/{}/ \ \n".format(
|
||||
python_download_url.split("/")[-1].split('.tgz')[0],
|
||||
python_version
|
||||
)
|
||||
dockerfile += "\u0009&& rm -rf {} \ \n".format(
|
||||
python_download_url.split("/")[-1])
|
||||
dockerfile += "\u0009&& rm -rf {} \n\n".format(
|
||||
python_download_url.split("/")[-1].split('.tgz')[0])
|
||||
|
||||
dockerfile += "# Blender comes with a super outdated version of numpy (which is needed for matplotlib / opencv) so override it with a modern one\n"
|
||||
dockerfile += "RUN rm -rf ${BLENDER_PATH}/python/lib/python3.7/site-packages/numpy \n\n"
|
||||
dockerfile += "RUN rm -rf {}/python/lib/{}/site-packages/numpy \n\n".format(
|
||||
"${BLENDER_PATH}", python_version)
|
||||
|
||||
dockerfile += "# Must first ensurepip to install Blender pip3 and then new numpy\n"
|
||||
dockerfile += "RUN ${BLENDERPY} -m ensurepip && ${BLENDERPIP} install --upgrade pip && ${BLENDERPIP} install numpy\n\n"
|
||||
|
@ -124,6 +133,8 @@ if __name__ == "__main__":
|
|||
env=manifest["env"] + image["env"],
|
||||
deps=manifest["deps"],
|
||||
blender_download_url=image["blender_download_url"],
|
||||
python_download_url=image["python_download_url"],
|
||||
python_version=image["python_version"],
|
||||
workdir="/"
|
||||
)
|
||||
|
||||
|
|
|
@ -25,6 +25,8 @@
|
|||
"tag": "2.80-cpu-ubuntu18.04",
|
||||
"base_os_image": "ubuntu:18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.80/blender-2.80-linux-glibc217-x86_64.tar.bz2",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.80/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.80\"",
|
||||
|
@ -37,6 +39,8 @@
|
|||
"tag": "2.80-gpu-ubuntu18.04",
|
||||
"base_os_image": "nvidia/cudagl:10.1-base-ubuntu18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.80/blender-2.80-linux-glibc217-x86_64.tar.bz2",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.80/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.80\"",
|
||||
|
@ -49,6 +53,8 @@
|
|||
"tag": "2.81-cpu-ubuntu18.04",
|
||||
"base_os_image": "ubuntu:18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.81/blender-2.81-linux-glibc217-x86_64.tar.bz2",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.81/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.81\"",
|
||||
|
@ -61,6 +67,8 @@
|
|||
"tag": "2.81-gpu-ubuntu18.04",
|
||||
"base_os_image": "nvidia/cudagl:10.1-base-ubuntu18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.81/blender-2.81-linux-glibc217-x86_64.tar.bz2",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.81/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.81\"",
|
||||
|
@ -73,6 +81,8 @@
|
|||
"tag": "2.82-cpu-ubuntu18.04",
|
||||
"base_os_image": "ubuntu:18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.82/blender-2.82-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.82/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.82\"",
|
||||
|
@ -85,6 +95,8 @@
|
|||
"tag": "2.82-gpu-ubuntu18.04",
|
||||
"base_os_image": "nvidia/cudagl:10.1-base-ubuntu18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.82/blender-2.82-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.82/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.82\"",
|
||||
|
@ -97,6 +109,8 @@
|
|||
"tag": "2.83-cpu-ubuntu18.04",
|
||||
"base_os_image": "ubuntu:18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.83/blender-2.83.0-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.83/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.83\"",
|
||||
|
@ -109,6 +123,8 @@
|
|||
"tag": "2.83-gpu-ubuntu18.04",
|
||||
"base_os_image": "nvidia/cudagl:10.1-base-ubuntu18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.83/blender-2.83.0-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.83/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.83\"",
|
||||
|
@ -121,6 +137,8 @@
|
|||
"tag": "2.90-cpu-ubuntu18.04",
|
||||
"base_os_image": "ubuntu:18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.90/blender-2.90.0-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.90/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.90\"",
|
||||
|
@ -133,6 +151,8 @@
|
|||
"tag": "2.90-gpu-ubuntu18.04",
|
||||
"base_os_image": "nvidia/cudagl:10.1-base-ubuntu18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.90/blender-2.90.0-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.90/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.90\"",
|
||||
|
@ -145,6 +165,8 @@
|
|||
"tag": "2.91-cpu-ubuntu18.04",
|
||||
"base_os_image": "ubuntu:18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.91/blender-2.91.0-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.91/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.91\"",
|
||||
|
@ -157,6 +179,8 @@
|
|||
"tag": "2.91-gpu-ubuntu18.04",
|
||||
"base_os_image": "nvidia/cudagl:10.1-base-ubuntu18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.91/blender-2.91.0-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.91/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.91\"",
|
||||
|
@ -169,6 +193,8 @@
|
|||
"tag": "2.92-cpu-ubuntu18.04",
|
||||
"base_os_image": "ubuntu:18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.92/blender-2.92.0-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.92/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.92\"",
|
||||
|
@ -181,6 +207,8 @@
|
|||
"tag": "2.92-gpu-ubuntu18.04",
|
||||
"base_os_image": "nvidia/cudagl:10.1-base-ubuntu18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.92/blender-2.92.0-linux64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.7.0/Python-3.7.0.tgz",
|
||||
"python_version": "python3.7m",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.92/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.92\"",
|
||||
|
@ -188,6 +216,34 @@
|
|||
"BLENDERPY \"/bin/2.92/python/bin/python3.7m\"",
|
||||
"HW=\"GPU\""
|
||||
]
|
||||
},
|
||||
{
|
||||
"tag": "2.93-cpu-ubuntu18.04",
|
||||
"base_os_image": "ubuntu:18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.93/blender-2.93.0-linux-x64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.9.1/Python-3.9.1.tgz",
|
||||
"python_version": "python3.9",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.93/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.93\"",
|
||||
"BLENDERPIP \"/bin/2.93/python/bin/pip3\"",
|
||||
"BLENDERPY \"/bin/2.93/python/bin/python3.9\"",
|
||||
"HW=\"CPU\""
|
||||
]
|
||||
},
|
||||
{
|
||||
"tag": "2.93-gpu-ubuntu18.04",
|
||||
"base_os_image": "nvidia/cudagl:10.1-base-ubuntu18.04",
|
||||
"blender_download_url": "https://mirror.clarkson.edu/blender/release/Blender2.93/blender-2.93.0-linux-x64.tar.xz",
|
||||
"python_download_url": "https://www.python.org/ftp/python/3.9.1/Python-3.9.1.tgz",
|
||||
"python_version": "python3.9",
|
||||
"env": [
|
||||
"PATH \"$PATH:/bin/2.93/python/bin/\"",
|
||||
"BLENDER_PATH \"/bin/2.93\"",
|
||||
"BLENDERPIP \"/bin/2.93/python/bin/pip3\"",
|
||||
"BLENDERPY \"/bin/2.93/python/bin/python3.9\"",
|
||||
"HW=\"GPU\""
|
||||
]
|
||||
}
|
||||
]
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue