From 37065f778967fcc7430a8887e28807c016151f39 Mon Sep 17 00:00:00 2001 From: Sean Dague Date: Tue, 7 Feb 2017 15:00:42 -0500 Subject: [PATCH] Support local_conf from project-config This adds the support for merging in local_conf from project config into local.conf files deployed in jobs. Change-Id: I81616a5b381fe203aef47628b52371609db5e5eb --- devstack-vm-gate.sh | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/devstack-vm-gate.sh b/devstack-vm-gate.sh index 13c61a8e..ff9a6c75 100755 --- a/devstack-vm-gate.sh +++ b/devstack-vm-gate.sh @@ -552,6 +552,28 @@ function setup_localrc { fi fi + # If you specify a section of a project-config job with + # + # local_conf: + # conf: | + # [[local|localrc]] + # foo=a + # [[post-config|$NEUTRON_CONF]] + # [DEFAULT] + # global_physnet_mtu = 1400 + # + # Then that whole local.conf fragment will get carried through to + # this special file, and we'll merge those values into *all* + # local.conf files in the job. That includes subnodes, and new & + # old in grenade. + # + # NOTE(sdague): the name of this file should be considered + # internal only, and jobs should not write to it directly, they + # should only use the project-config stanza. + if [[ -e "/tmp/dg-local.conf" ]]; then + $DSCONF merge_lc "$localrc_file" "/tmp/dg-local.conf" + fi + # a way to pass through arbitrary devstack config options so that # we don't need to add new devstack-gate options every time we # want to create a new config.