From 84626c82cc54a0b1de595cbac06336045947dc4a Mon Sep 17 00:00:00 2001 From: Dan Prince Date: Sun, 29 Jan 2017 08:01:46 -0500 Subject: Add docker_puppet_tasks initialization on primary node This patch adds a new (optional) section to the docker post.j2.yaml that collects any 'docker_puppet_tasks' data from enabled services and applies it on the primary role node (the first node in the primary (first) role). The use case for this is although we are generally only using puppet for configuration there are several exceptions that we desire to make use of today for parity with baremetal. This includes things like database creation and keystone endpoint initialization which we rely on configuration via hiera variables controlled by the puppet services. Change-Id: Ic14ef48f26de761b0d0eabd0e1c0eae52d90e68a --- docker/docker-puppet.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'docker/docker-puppet.py') diff --git a/docker/docker-puppet.py b/docker/docker-puppet.py index 2d560819..fe87ce7a 100755 --- a/docker/docker-puppet.py +++ b/docker/docker-puppet.py @@ -72,7 +72,9 @@ with open(config_file) as f: configs = {} -for service in json_data: +for service in (json_data or []): + if service is None: + continue config_volume = service[0] or '' puppet_tags = service[1] or '' manifest = service[2] or '' -- cgit 1.2.3-korg