diff options
author | Juan Antonio Osorio Robles <jaosorior@redhat.com> | 2017-03-16 13:20:41 +0200 |
---|---|---|
committer | Juan Antonio Osorio Robles <jaosorior@redhat.com> | 2017-03-22 10:11:21 +0200 |
commit | 7f5c616a949dc1649ac22484d7fd059b04cae6c5 (patch) | |
tree | cadbf815eed6cc5b1c383204d7afce580262fb08 /docker | |
parent | b758dff5758a84b8a72766dd2591477f68b23c50 (diff) |
docker-puppet: skip empty volume entries
This allows to optionally add volumes, where we could use a heat
conditional to either put the volume path we want or put an empty string
which should be safely skipped.
Change-Id: I68f91ffdd8ceb14735adad1322fcf124c47b160c
Diffstat (limited to 'docker')
-rwxr-xr-x | docker/docker-puppet.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/docker/docker-puppet.py b/docker/docker-puppet.py index 0f079436..8f95208f 100755 --- a/docker/docker-puppet.py +++ b/docker/docker-puppet.py @@ -205,7 +205,8 @@ def mp_puppet_config((config_volume, puppet_tags, manifest, config_image, volume '--volume', '%s:%s:rw' % (sh_script, sh_script) ] for volume in volumes: - dcmd.extend(['--volume', volume]) + if volume: + dcmd.extend(['--volume', volume]) dcmd.extend(['--entrypoint', sh_script]) |