kopia lustrzana https://github.com/nytimes/rd-blender-docker
remove trailing whitespaces from generated Dockerfile
rodzic
9ee23b3959
commit
69ee700f96
16
generate.py
16
generate.py
|
@ -58,7 +58,7 @@ def create_dockerfile(base_os: str,
|
||||||
dockerfile += "\n"
|
dockerfile += "\n"
|
||||||
|
|
||||||
dockerfile += "# Install dependencies\n"
|
dockerfile += "# Install dependencies\n"
|
||||||
dockerfile += "RUN apt-get update && apt-get install -y \ \n"
|
dockerfile += "RUN apt-get update && apt-get install -y \\\n"
|
||||||
|
|
||||||
archivetype = blender_download_url.split(".")[-1]
|
archivetype = blender_download_url.split(".")[-1]
|
||||||
archiveflags = "xjvf"
|
archiveflags = "xjvf"
|
||||||
|
@ -78,23 +78,23 @@ def create_dockerfile(base_os: str,
|
||||||
dockerfile += "\n"
|
dockerfile += "\n"
|
||||||
|
|
||||||
dockerfile += "# Download and install Blender\n"
|
dockerfile += "# Download and install Blender\n"
|
||||||
dockerfile += "RUN wget {} \ \n".format(blender_download_url)
|
dockerfile += "RUN wget {} \\\n".format(blender_download_url)
|
||||||
dockerfile += "\u0009&& tar -{} {} --strip-components=1 -C /bin \ \n".format(
|
dockerfile += "\u0009&& tar -{} {} --strip-components=1 -C /bin \\\n".format(
|
||||||
archiveflags, blender_download_url.split("/")[-1])
|
archiveflags, blender_download_url.split("/")[-1])
|
||||||
dockerfile += "\u0009&& rm -rf {} \ \n".format(
|
dockerfile += "\u0009&& rm -rf {} \\\n".format(
|
||||||
blender_download_url.split("/")[-1])
|
blender_download_url.split("/")[-1])
|
||||||
dockerfile += "\u0009&& rm -rf {}\n\n".format(
|
dockerfile += "\u0009&& rm -rf {}\n\n".format(
|
||||||
blender_download_url.split("/")[-1].split(".tar."+archivetype)[0])
|
blender_download_url.split("/")[-1].split(".tar."+archivetype)[0])
|
||||||
|
|
||||||
dockerfile += "# Download the Python source since it is not bundled with Blender\n"
|
dockerfile += "# Download the Python source since it is not bundled with Blender\n"
|
||||||
dockerfile += "RUN wget {} \ \n".format(python_download_url)
|
dockerfile += "RUN wget {} \\\n".format(python_download_url)
|
||||||
dockerfile += "\u0009&& tar -xzf {} \ \n".format(
|
dockerfile += "\u0009&& tar -xzf {} \\\n".format(
|
||||||
python_download_url.split("/")[-1])
|
python_download_url.split("/")[-1])
|
||||||
dockerfile += "\u0009&& cp -r {}/Include/* $BLENDER_PATH/python/include/{}/ \ \n".format(
|
dockerfile += "\u0009&& cp -r {}/Include/* $BLENDER_PATH/python/include/{}/ \\\n".format(
|
||||||
python_download_url.split("/")[-1].split('.tgz')[0],
|
python_download_url.split("/")[-1].split('.tgz')[0],
|
||||||
python_version
|
python_version
|
||||||
)
|
)
|
||||||
dockerfile += "\u0009&& rm -rf {} \ \n".format(
|
dockerfile += "\u0009&& rm -rf {} \\\n".format(
|
||||||
python_download_url.split("/")[-1])
|
python_download_url.split("/")[-1])
|
||||||
dockerfile += "\u0009&& rm -rf {}\n\n".format(
|
dockerfile += "\u0009&& rm -rf {}\n\n".format(
|
||||||
python_download_url.split("/")[-1].split('.tgz')[0])
|
python_download_url.split("/")[-1].split('.tgz')[0])
|
||||||
|
|
Ładowanie…
Reference in New Issue