kopia lustrzana https://github.com/jupyterhub/repo2docker
add assemble_subset
- get_assemble_files() returns list of files needed for assembly - if buildpack.assemble_with_subset is set, only load assemble_files prior to running assembly scripts. Load the rest of the repo afterward conda opts in to this, but currently I think this works for everything *except* requirements.txtpull/743/head
rodzic
5ef42fc2af
commit
5cf4f786e8
|
@ -178,6 +178,18 @@ class CondaBuildPack(BaseImage):
|
||||||
"""Am I building a Python 2 kernel environment?"""
|
"""Am I building a Python 2 kernel environment?"""
|
||||||
return self.python_version and self.python_version.split(".")[0] == "2"
|
return self.python_version and self.python_version.split(".")[0] == "2"
|
||||||
|
|
||||||
|
def get_assemble_files(self):
|
||||||
|
"""Specify that assembly only requires environment.yml
|
||||||
|
|
||||||
|
enables caching assembly result even when
|
||||||
|
repo contents change
|
||||||
|
"""
|
||||||
|
assemble_files = super().get_assemble_files()
|
||||||
|
environment_yml = self.binder_path('environment.yml')
|
||||||
|
if os.path.exists(environment_yml):
|
||||||
|
assemble_files.append(environment_yml)
|
||||||
|
return assemble_files
|
||||||
|
|
||||||
def get_assemble_scripts(self):
|
def get_assemble_scripts(self):
|
||||||
"""Return series of build-steps specific to this source repository.
|
"""Return series of build-steps specific to this source repository.
|
||||||
"""
|
"""
|
||||||
|
|
Ładowanie…
Reference in New Issue