kopia lustrzana https://github.com/jupyterhub/repo2docker
Add Dockerfile repo2docker labels
rodzic
eb272875b1
commit
2e31e6e80e
|
@ -745,6 +745,11 @@ class Repo2Docker(Application):
|
|||
picked_buildpack = self.default_buildpack()
|
||||
|
||||
picked_buildpack.appendix = self.appendix
|
||||
picked_buildpack.labels = {
|
||||
'repo2docker.version': self.version,
|
||||
'repo2docker.repo': self.repo,
|
||||
'repo2docker.ref': self.ref,
|
||||
}
|
||||
|
||||
self.log.debug(picked_buildpack.render(),
|
||||
extra=dict(phase='building'))
|
||||
|
|
|
@ -120,8 +120,8 @@ ENV {{item[0]}} {{item[1]}}
|
|||
# Container image Labels!
|
||||
# Put these at the end, since we don't want to rebuild everything
|
||||
# when these change! Did I mention I hate Dockerfile cache semantics?
|
||||
{% for k, v in labels.items() -%}
|
||||
LABEL {{k}}={{v}}
|
||||
{% for k, v in labels.items() %}
|
||||
LABEL {{k}}="{{v}}"
|
||||
{%- endfor %}
|
||||
|
||||
# We always want containers to run as non-root
|
||||
|
@ -246,7 +246,7 @@ class BuildPack:
|
|||
"""
|
||||
Docker labels to set on the built image.
|
||||
"""
|
||||
return {}
|
||||
return getattr(self, 'labels', {})
|
||||
|
||||
def get_build_script_files(self):
|
||||
"""
|
||||
|
|
Ładowanie…
Reference in New Issue