From e5d468a42cda7b477418d78a8b67c5471cc223a1 Mon Sep 17 00:00:00 2001 From: Alex Schultz Date: Wed, 8 Mar 2017 12:25:56 -0700 Subject: [PATCH] Actually run service validation for designate The service validation for designate-central was set to refreshonly but did not have anything actually notifying it to run. This change updates the validation to listen for the designate::service::end anchor so that we will wait for the service to be up before trying to manage the pools. Change-Id: Ife6b29388e97112666ad5602ac62ac7d8534c1d5 Closes-Bug: #1671206 --- manifests/designate.pp | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/manifests/designate.pp b/manifests/designate.pp index 4a1ed115d..595fd6e13 100644 --- a/manifests/designate.pp +++ b/manifests/designate.pp @@ -98,13 +98,6 @@ class openstack_integration::designate { rndc_key_file => $::dns::params::rndckeypath, } - # TODO: Implement pools.yaml management in puppet-designate - file { '/etc/designate/pools.yaml': - ensure => present, - content => template("${module_name}/pools.yaml.erb"), - require => Service['designate-central'], - } - # Validate that designate-central is ready for pool update $command = "openstack --os-auth-url ${::openstack_integration::config::keystone_auth_uri} \ --os-project-name services --os-username designate --os-password a_big_secret zone list" @@ -112,6 +105,14 @@ class openstack_integration::designate { command => $command, timeout => '15', refreshonly => true, + subscribe => Anchor['designate::service::end'], + } + + # TODO: Implement pools.yaml management in puppet-designate + file { '/etc/designate/pools.yaml': + ensure => present, + content => template("${module_name}/pools.yaml.erb"), + require => Service['designate-central'], } exec { 'Update designate pools': @@ -120,6 +121,6 @@ class openstack_integration::designate { refreshonly => true, logoutput => 'on_failure', subscribe => File['/etc/designate/pools.yaml'], - require => Anchor['create designate-central anchor'], + require => Openstacklib::Service_validation['designate-central'], } }