summaryrefslogtreecommitdiffstats
path: root/manifests
diff options
context:
space:
mode:
authorDmitry Tantsur <divius.inside@gmail.com>2016-07-20 12:05:51 +0200
committerDmitry Tantsur <divius.inside@gmail.com>2016-07-20 12:05:51 +0200
commitfa4c306485338e7ed95fabbb5d9839cda59e93df (patch)
tree68503fcc58f7e3d2a9264bb2c9685350f4fc8d5d /manifests
parent5927148c4b5813180204c2983b5c95b69a2ad265 (diff)
Fix Ironic dbsync ordering
Including ::ironic runs ironic-dbsync by default, so we end up with ironic-dbsync run before the database is created. This patch fixes it. Change-Id: I6fef1de18e52b68caaf4cbd55c0408b98b5c26e0 Partially-Implements: blueprint ironic-integration
Diffstat (limited to 'manifests')
-rw-r--r--manifests/profile/base/ironic.pp13
1 files changed, 7 insertions, 6 deletions
diff --git a/manifests/profile/base/ironic.pp b/manifests/profile/base/ironic.pp
index dd30dd7..ca4f366 100644
--- a/manifests/profile/base/ironic.pp
+++ b/manifests/profile/base/ironic.pp
@@ -30,19 +30,20 @@ class tripleo::profile::base::ironic (
$bootstrap_node = hiera('bootstrap_nodeid', undef),
$step = hiera('step'),
) {
+ # Database is accessed by both API and conductor, hence it's here.
if $::hostname == downcase($bootstrap_node) {
$sync_db = true
} else {
$sync_db = false
}
- if $step >= 3 {
- include ::ironic
+ if $step >= 3 and $sync_db {
+ include ::ironic::db::mysql
+ }
- # Database is accessed by both API and conductor, hence it's here.
- if $sync_db {
- include ::ironic::db::mysql
- include ::ironic::db::sync
+ if $step >= 4 or ($step >= 3 and $sync_db) {
+ class { '::ironic':
+ sync_db => $sync_db,
}
}
}