Bug 1631806 - deployment through colonizer fails due to wrong playbook path in colonizer.py
Summary: deployment through colonizer fails due to wrong playbook path in colonizer.py
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat Storage
Component: gluster-colonizer
Version: rhgs-3.4
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: ---
: RHGS 3.4.z Async Update
Assignee: Ramakrishna Reddy Yekulla
QA Contact: Nag Pavan Chilakam
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-09-21 15:23 UTC by Nag Pavan Chilakam
Modified: 2018-11-05 11:06 UTC (History)
8 users (show)

Fixed In Version: gluster-colonizer-1.2-3
Doc Type: No Doc Update
Doc Text:
undefined
Clone Of:
Environment:
Last Closed: 2018-11-05 11:06:45 UTC
Embargoed:


Attachments (Terms of Use)
playbook path downstream fix.patch (1.45 KB, patch)
2018-09-23 19:01 UTC, Ramakrishna Reddy Yekulla
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:3465 0 None None None 2018-11-05 11:06:51 UTC

Description Nag Pavan Chilakam 2018-09-21 15:23:47 UTC
Description of problem:
====================
media server deployment through colonizer fails due to wrong playbook path in colonizer.py

error : playbook /usr/share/gluster-colonizer/ansible//g1-reset.yml could not be found

the playbook_path is currently /g1_path + 'ansible' , which is wrong
it should be g1_path+'playbook/ansible'

I did the above changes manually and it worked



Version-Release number of selected component (if applicable):
===========
colonizer-1.2.2

How reproducible:
===========
always

Steps to Reproduce:
1.deploy media server, enter all till passwd
2.after that deployment fails with file not found


Expected results:
=================
wrong playbook path, needs to be corrected


I did it manually and it worked 

Additional info:

Comment 2 Dustin Black 2018-09-21 15:27:55 UTC
Updated the title since this issue is not isolated to the media config. The problem is in the gluster-colonizer.py script, where a downstream change is required to support a path change for the ansible playbooks.

Comment 5 Ramakrishna Reddy Yekulla 2018-09-23 19:01:44 UTC
Created attachment 1486247 [details]
playbook path downstream fix.patch

Comment 6 Ramakrishna Reddy Yekulla 2018-09-23 19:07:31 UTC
Definitely a build regression. Patch did not apply in the build.
I have fixed the issue.

Comment 10 Nag Pavan Chilakam 2018-10-23 09:27:32 UTC
checked latest colonizer and the path
 has been corrected
[root@dhcp46-80 ~]# rpm -qa|grep colonizer
gluster-colonizer-1.2-3.el7rhgs.noarch


playbook path is now "playbook_path = g1_path + "playbook/ansible/""


[root@dhcp46-80 ~]# cat /usr/bin/gluster-colonizer.py |grep path
g1_path = oem_id['flavor']['g1_path']
branding_file = "%sbranding.yml" % g1_path
playbook_path = g1_path + "playbook/ansible/"
        run_ansible_playbook(playbook_path + '/g1-key-dist.yml', False, True, True, True)
        run_ansible_playbook(playbook_path + '/g1-bootstrap.yml')
        flavor_path = g1_path + 'oemid/' + oem_id['flavor']['node']['flavor_path']
        # Add custom module path and import flavor module
        sys.path.insert(0, flavor_path)
        run_ansible_playbook(flavor_path +
        run_ansible_playbook(g1_path + 'oemid/' +
    playbook_args = playbook_path + '/g1-reset.yml --user ansible --extra-vars="{cache_devices: ' + str(cache_devices) + ',arbiter: ' +  str('yes' if str(oem_id['flavor']['arbiter_size_factor']) != "None" else 'no') + ',backend_configuration: ' + str( backend_configuration ) + '}"'
        customizationFile = flavor_path + oem_id['flavor']['node']['customization_file_name']
        if not os.path.isfile(customizationFile):
    playbook_args = playbook_path + '/g1-deploy.yml --extra-vars="{cache_devices: ' + str(
        run_ansible_playbook(playbook_path + "/g1-key-dist.yml")
        playbook_args = playbook_path + '/g1-smb-ad.yml --extra-vars="{'
        run_ansible_playbook(playbook_path + '/g1-smb-ad-restart-services.yml', continue_on_fail=True)
        run_ansible_playbook(playbook_path + "/g1-root-pw.yml" + " --extra-vars=\"{root_password_hashed: " + re.sub('\$', '\\\$', root_password_hashed) + "}\"", continue_on_fail=True)
    playbook_args = playbook_path + '/g1-post-install.yml --extra-vars="{'
        playbook_args = playbook_path + '/g1-perf-test.yml --extra-vars="{default_volname: ' + str(




hence moving to verified

Comment 13 errata-xmlrpc 2018-11-05 11:06:45 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:3465


Note You need to log in before you can comment on or make changes to this bug.