Add 'openstack-db' tag to db-sync Exec resource
In order to make easy orchestration on all OpenStack db-sync, add this
tag so people can use this tag in composition layer.
A use case it to set some orchestration to make sure MySQL Galera is
ready before running any Exec with this tag.
Change-Id: I0769f75d92e87d686387286041502261fad871e7
Closes-Bug: #1755102
(cherry picked from commit f5078648ea
)
This commit is contained in:
parent
ae5a4fba2d
commit
dcfb0d345f
|
@ -20,6 +20,7 @@ class mistral::db::sync {
|
|||
Anchor['mistral::dbsync::begin']
|
||||
],
|
||||
notify => Anchor['mistral::dbsync::end'],
|
||||
tag => 'openstack-db',
|
||||
}
|
||||
|
||||
exec { 'mistral-db-populate':
|
||||
|
@ -35,6 +36,7 @@ class mistral::db::sync {
|
|||
Anchor['mistral::dbsync::begin']
|
||||
],
|
||||
notify => Anchor['mistral::dbsync::end'],
|
||||
tag => 'openstack-db',
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
features:
|
||||
- Add openstack-db tag to Exec that run db-sync.
|
|
@ -13,7 +13,8 @@ describe 'mistral::db::sync' do
|
|||
:refreshonly => 'true',
|
||||
:try_sleep => 5,
|
||||
:tries => 10,
|
||||
:logoutput => 'on_failure'
|
||||
:logoutput => 'on_failure',
|
||||
:tag => 'openstack-db',
|
||||
)
|
||||
|
||||
is_expected.to contain_exec('mistral-db-populate').with(
|
||||
|
@ -21,7 +22,8 @@ describe 'mistral::db::sync' do
|
|||
:path => '/usr/bin',
|
||||
:user => 'mistral',
|
||||
:refreshonly => 'true',
|
||||
:logoutput => 'on_failure'
|
||||
:logoutput => 'on_failure',
|
||||
:tag => 'openstack-db',
|
||||
)
|
||||
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue