Replace outdated command to create rally db
The rally-manage db command was already replaced by the rally db command[1]. This fixes the outdated command still used. [1] https://review.opendev.org/c/openstack/rally/+/681224 Closes-Bug: #2002372 Change-Id: I34570e7c4131c3f06a1da23e9f2e57eec75ff25a
This commit is contained in:
parent
a179d50c74
commit
16a35f2fc6
@ -5,8 +5,8 @@
|
||||
#
|
||||
# [*extra_params*]
|
||||
# (Optional) String of extra command line parameters to append
|
||||
# to the rally-manage db sync command. These will be inserted
|
||||
# in the command line between 'rally-manage' and 'db create'.
|
||||
# to the rally db sync command. These will be inserted in the command line
|
||||
# between 'rally' and 'db create'.
|
||||
# Defaults to '--config-file /etc/rally/rally.conf'
|
||||
#
|
||||
# [*db_sync_timeout*]
|
||||
@ -20,8 +20,8 @@ class rally::db::sync(
|
||||
|
||||
include rally::deps
|
||||
|
||||
exec { 'rally-manage db_sync':
|
||||
command => "rally-manage ${extra_params} db create",
|
||||
exec { 'rally db_sync':
|
||||
command => "rally ${extra_params} db create",
|
||||
path => '/usr/bin',
|
||||
user => 'root',
|
||||
refreshonly => true,
|
||||
|
@ -6,9 +6,9 @@ describe 'rally::db::sync' do
|
||||
|
||||
it { is_expected.to contain_class('rally::deps') }
|
||||
|
||||
it 'runs rally-manage db_sync' do
|
||||
is_expected.to contain_exec('rally-manage db_sync').with(
|
||||
:command => 'rally-manage --config-file /etc/rally/rally.conf db create',
|
||||
it 'runs rally db_sync' do
|
||||
is_expected.to contain_exec('rally db_sync').with(
|
||||
:command => 'rally --config-file /etc/rally/rally.conf db create',
|
||||
:user => 'root',
|
||||
:path => '/usr/bin',
|
||||
:refreshonly => 'true',
|
||||
@ -24,33 +24,32 @@ describe 'rally::db::sync' do
|
||||
)
|
||||
end
|
||||
|
||||
describe "overriding params" do
|
||||
let :params do
|
||||
{
|
||||
:extra_params => '--config-file /var/lib/rally/rally.conf',
|
||||
:db_sync_timeout => 750,
|
||||
context "overriding params" do
|
||||
let :params do
|
||||
{
|
||||
:extra_params => '--config-file /var/lib/rally/rally.conf',
|
||||
:db_sync_timeout => 750,
|
||||
}
|
||||
end
|
||||
|
||||
it {
|
||||
is_expected.to contain_exec('rally db_sync').with(
|
||||
:command => 'rally --config-file /var/lib/rally/rally.conf db create',
|
||||
:user => 'root',
|
||||
:path => '/usr/bin',
|
||||
:refreshonly => 'true',
|
||||
:try_sleep => 5,
|
||||
:tries => 10,
|
||||
:timeout => 750,
|
||||
:logoutput => 'on_failure',
|
||||
:subscribe => ['Anchor[rally::install::end]',
|
||||
'Anchor[rally::config::end]',
|
||||
'Anchor[rally::dbsync::begin]'],
|
||||
:notify => 'Anchor[rally::dbsync::end]',
|
||||
:tag => 'openstack-db',
|
||||
)
|
||||
}
|
||||
end
|
||||
|
||||
it {
|
||||
is_expected.to contain_exec('rally-manage db_sync').with(
|
||||
:command => 'rally-manage --config-file /var/lib/rally/rally.conf db create',
|
||||
:user => 'root',
|
||||
:path => '/usr/bin',
|
||||
:refreshonly => 'true',
|
||||
:try_sleep => 5,
|
||||
:tries => 10,
|
||||
:timeout => 750,
|
||||
:logoutput => 'on_failure',
|
||||
:subscribe => ['Anchor[rally::install::end]',
|
||||
'Anchor[rally::config::end]',
|
||||
'Anchor[rally::dbsync::begin]'],
|
||||
:notify => 'Anchor[rally::dbsync::end]',
|
||||
:tag => 'openstack-db',
|
||||
)
|
||||
}
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
on_supported_os({
|
||||
|
Loading…
Reference in New Issue
Block a user