Browse Source

[only-train] BnR overwrite the json output

The default output for the run_ansible_playbooks is json,
this patch modifies the output to tripleo, so it will be easier for
operators to see the outcome.

The default output from ussuri is tripleo_dense.

Change-Id: Ieb21ff1cd348bff275a14420e3af8a65f401d631
changes/59/788459/3
Juan Badia Payno 2 weeks ago
parent
commit
e2cba545ce
4 changed files with 22 additions and 0 deletions
  1. +10
    -0
      tripleoclient/tests/v1/overcloud_backup/test_backup.py
  2. +10
    -0
      tripleoclient/tests/v1/undercloud/test_backup.py
  3. +1
    -0
      tripleoclient/v1/overcloud_backup.py
  4. +1
    -0
      tripleoclient/v1/undercloud_backup.py

+ 10
- 0
tripleoclient/tests/v1/overcloud_backup/test_backup.py View File

@ -50,6 +50,7 @@ class TestOvercloudBackup(utils.TestCommand):
playbook='cli-overcloud-backup.yaml',
inventory=parsed_args.inventory,
tags='bar_create_recover_image',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars={}
@ -72,6 +73,7 @@ class TestOvercloudBackup(utils.TestCommand):
playbook='prepare-overcloud-backup.yaml',
inventory=parsed_args.inventory,
tags='bar_setup_rear',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars={}
@ -95,6 +97,7 @@ class TestOvercloudBackup(utils.TestCommand):
playbook='prepare-nfs-backup.yaml',
inventory=parsed_args.inventory,
tags='bar_setup_nfs_server',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars={}
@ -117,6 +120,7 @@ class TestOvercloudBackup(utils.TestCommand):
playbook='prepare-nfs-backup.yaml',
inventory=parsed_args.inventory,
tags='bar_setup_nfs_server',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars={}
@ -139,6 +143,7 @@ class TestOvercloudBackup(utils.TestCommand):
playbook='prepare-overcloud-backup.yaml',
inventory=parsed_args.inventory,
tags='bar_setup_rear',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars={}
@ -164,6 +169,7 @@ class TestOvercloudBackup(utils.TestCommand):
playbook='prepare-nfs-backup.yaml',
inventory=parsed_args.inventory,
tags='bar_setup_nfs_server',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars={}),
@ -171,6 +177,7 @@ class TestOvercloudBackup(utils.TestCommand):
workdir=constants.ANSIBLE_TRIPLEO_PLAYBOOKS,
playbook='prepare-overcloud-backup.yaml',
inventory=parsed_args.inventory,
output_callback='tripleo',
tags='bar_setup_rear',
skip_tags=None,
verbosity=1,
@ -201,6 +208,7 @@ class TestOvercloudBackup(utils.TestCommand):
playbook='prepare-overcloud-backup.yaml',
inventory=parsed_args.inventory,
tags='bar_setup_rear',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars=extra_vars_dict
@ -225,6 +233,7 @@ class TestOvercloudBackup(utils.TestCommand):
playbook='prepare-overcloud-backup.yaml',
inventory=parsed_args.inventory,
tags='bar_setup_rear',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars='/tmp/test_vars.yaml'
@ -249,6 +258,7 @@ class TestOvercloudBackup(utils.TestCommand):
inventory=parsed_args.inventory,
tags='bar_create_recover_image',
skip_tags=None,
output_callback='tripleo',
verbosity=1,
extra_vars={}
)

+ 10
- 0
tripleoclient/tests/v1/undercloud/test_backup.py View File

@ -130,6 +130,7 @@ class TestUndercloudBackup(utils.TestCommand):
inventory=mock.ANY,
tags='bar_create_recover_image',
skip_tags=None,
output_callback='tripleo',
verbosity=1,
extra_vars=None
)
@ -152,6 +153,7 @@ class TestUndercloudBackup(utils.TestCommand):
inventory=mock.ANY,
tags='bar_setup_rear',
skip_tags=None,
output_callback='tripleo',
verbosity=1,
extra_vars=None
)
@ -174,6 +176,7 @@ class TestUndercloudBackup(utils.TestCommand):
playbook='prepare-nfs-backup.yaml',
inventory=mock.ANY,
tags='bar_setup_nfs_server',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars=None
@ -195,6 +198,7 @@ class TestUndercloudBackup(utils.TestCommand):
workdir=constants.ANSIBLE_TRIPLEO_PLAYBOOKS,
playbook='prepare-nfs-backup.yaml',
inventory=mock.ANY,
output_callback='tripleo',
tags='bar_setup_nfs_server',
skip_tags=None,
verbosity=1,
@ -218,6 +222,7 @@ class TestUndercloudBackup(utils.TestCommand):
playbook='prepare-undercloud-backup.yaml',
inventory=mock.ANY,
tags='bar_setup_rear',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars=None
@ -248,6 +253,7 @@ class TestUndercloudBackup(utils.TestCommand):
tags='bar_setup_rear',
skip_tags=None,
verbosity=1,
output_callback='tripleo',
extra_vars=extra_vars_dict
)
@ -272,6 +278,7 @@ class TestUndercloudBackup(utils.TestCommand):
inventory=mock.ANY,
tags='bar_setup_nfs_server',
skip_tags=None,
output_callback='tripleo',
verbosity=1,
extra_vars=None),
call(logger=mock.ANY,
@ -280,6 +287,7 @@ class TestUndercloudBackup(utils.TestCommand):
inventory=mock.ANY,
tags='bar_setup_rear',
skip_tags=None,
output_callback='tripleo',
verbosity=1,
extra_vars=None)]
@ -306,6 +314,7 @@ class TestUndercloudBackup(utils.TestCommand):
tags='bar_setup_nfs_server',
skip_tags=None,
verbosity=1,
output_callback='tripleo',
extra_vars='/tmp/test_vars.yaml'
)
@ -327,6 +336,7 @@ class TestUndercloudBackup(utils.TestCommand):
playbook='cli-undercloud-backup.yaml',
inventory=mock.ANY,
tags='bar_create_recover_image',
output_callback='tripleo',
skip_tags=None,
verbosity=1,
extra_vars=None


+ 1
- 0
tripleoclient/v1/overcloud_backup.py View File

@ -189,6 +189,7 @@ class BackupOvercloud(command.Command):
tags=tags,
skip_tags=skip_tags,
verbosity=self.app_args.verbose_level,
output_callback='tripleo',
extra_vars=extra_vars
)


+ 1
- 0
tripleoclient/v1/undercloud_backup.py View File

@ -191,6 +191,7 @@ class BackupUndercloud(command.Command):
tags=tags,
skip_tags=skip_tags,
verbosity=self.app_args.verbose_level,
output_callback='tripleo',
extra_vars=extra_vars
)


Loading…
Cancel
Save