<div dir="ltr"><div dir="ltr"><div><div class="gmail_quote"><div dir="ltr">On Sun, Sep 30, 2018 at 6:45 PM Sachidananda URS &lt;<a href="mailto:surs@redhat.com">surs@redhat.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Sep 30, 2018 at 12:56 PM, Yaniv Kaul <span dir="ltr">&lt;<a href="mailto:ykaul@redhat.com" target="_blank">ykaul@redhat.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div style="font-family:arial,helvetica,sans-serif"><br></div><br><div class="gmail_quote"><div><div class="gmail-m_-1735954367171863643gmail-h5"><div dir="ltr">On Fri, Sep 28, 2018 at 2:33 PM Sachidananda URS &lt;<a href="mailto:surs@redhat.com" target="_blank">surs@redhat.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div>Hi,</div><div><br></div><div>gluster-ansible project is aimed at automating the deployment and maintenance of GlusterFS cluster.</div><div><br></div><div>The project can be found at:<br></div><div><br></div><div>* <a href="https://github.com/gluster/gluster-ansible" target="_blank">https://github.com/gluster/gluster-ansible</a></div><div>* <a href="https://github.com/gluster/gluster-ansible-infra" target="_blank">https://github.com/gluster/gluster-ansible-infra</a></div><div>* <a href="https://github.com/gluster/gluster-ansible-features" target="_blank">https://github.com/gluster/gluster-ansible-features</a></div><div>* <a href="https://github.com/gluster/gluster-ansible-maintenance" target="_blank">https://github.com/gluster/gluster-ansible-maintenance</a></div><div>* <a href="https://github.com/gluster/gluster-ansible-cluster" target="_blank">https://github.com/gluster/gluster-ansible-cluster</a></div><div>* <a href="https://github.com/gluster/gluster-ansible-repositories" target="_blank">https://github.com/gluster/gluster-ansible-repositories</a></div><div><br></div><div>We have the python bindings for GlusterD2 API, and can be found at:</div><div><br></div><div><a href="https://github.com/gluster/python-gluster-mgmt-client" target="_blank">https://github.com/gluster/python-gluster-mgmt-client</a></div><div><br></div><div>The goal is to use the python bindings in gluster_ansible module to make it work with GlusterD2.</div><div><br></div><div>Current status of the project:</div><div><br></div><div>* We have the initial working roles, packages are available at:</div><div>   - <a href="https://copr.fedorainfracloud.org/coprs/sac/gluster-ansible/builds/" target="_blank">https://copr.fedorainfracloud.org/coprs/sac/gluster-ansible/builds/</a></div><div><br></div><div>* The initial version supports:</div><div>   - End-to-end deployment of Gluster Hyperconverged Infrastructure.</div><div>   - GlusterFS volume management</div><div>   - GlusterFS brick setup</div><div>   - Packages and repository management <br></div><div><br></div><div>* Autogeneration of python bindings for GlusterD2 is being worked by Sidharth (<a href="https://github.com/sidharthanup" target="_blank">https://github.com/sidharthanup</a>) and available at:</div><div>  - <a href="https://github.com/sidharthanup/GD2_API/blob/master/testgen/glusterapi_README.md" target="_blank">https://github.com/sidharthanup/GD2_API/blob/master/testgen/glusterapi_README.md</a></div><div><br></div><div>The GD2 API python project will be merged into python-gluster-mgmt-client.</div><div><br></div><div>* Ansible modules (WIP):</div><div>   - New module: Facts module for self-heal and rebalance. Devyani is working on these modules.</div><div>     <a href="https://github.com/ansible/ansible/pull/45997" target="_blank">https://github.com/ansible/ansible/pull/45997</a> - self-heal</div><div>   - Remove brick feature for gluster_ansible module:</div><div>     <a href="https://github.com/ansible/ansible/pull/38269" target="_blank">https://github.com/ansible/ansible/pull/38269</a></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></blockquote><div><br></div></div></div><div style="font-family:arial,helvetica,sans-serif">Is there any work planned for dynamic inventory (<a href="https://docs.ansible.com/ansible/2.5/dev_guide/developing_inventory.html" target="_blank">https://docs.ansible.com/ansible/2.5/dev_guide/developing_inventory.html</a>) ?</div><div style="font-family:arial,helvetica,sans-serif">Peers, bricks and volumes are all good candidates for dynamic inventory.</div><span class="gmail-m_-1735954367171863643gmail-"><div style="font-family:arial,helvetica,sans-serif"></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div><br></div><div><br></div><div>* Sheersha and Nigel are working on continuous integration, and PR is at:<br></div><div>   - <a href="https://github.com/gluster/gluster-ansible-infra/pull/29" target="_blank">https://github.com/gluster/gluster-ansible-infra/pull/29</a></div><div>   - <a href="https://github.com/gluster/gluster-ansible-infra/pull/26" target="_blank">https://github.com/gluster/gluster-ansible-infra/pull/26</a></div><div><br></div><div>The CI work is in progress and will be integrated soon. Which will help us to keep the repository</div><div>in stable condition.</div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></div></blockquote><div><br></div></span><div style="font-family:arial,helvetica,sans-serif">I recommend running ansible-lint in CI. For example:</div><div><span style="font-family:arial,helvetica,sans-serif"></span><font face="arial, helvetica, sans-serif">[ykaul@ykaul gluster-ansible-infra]$ find . -name &quot;*.yml&quot; |xargs ansible-lint</font></div><div><font face="arial, helvetica, sans-serif">Syntax Error while loading YAML.</font></div><div><font face="arial, helvetica, sans-serif">  did not find expected &#39;,&#39; or &#39;}&#39;</font></div><div><font face="arial, helvetica, sans-serif"><br></font></div></div></div></div></div></div></blockquote><div><br></div><div>I remember Nigel and Sheersha running ansible-lint (or yaml-lint) on the roles. I think they run<br></div><div>on the tasks directory. But it is good idea to run on all the yamls.<br></div><div><br> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div class="gmail_quote"><div><font face="arial, helvetica, sans-serif"></font></div><div><font face="arial, helvetica, sans-serif">The error appears to have been in &#39;/home/ykaul/github/gluster-ansible-infra/examples/backend_with_vdo.yml&#39;: line 22, column 8, but may</font></div><div><font face="arial, helvetica, sans-serif">be elsewhere in the file depending on the exact syntax problem.</font></div><div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif">The offending line appears to be:</font></div><div><font face="arial, helvetica, sans-serif"><br></font></div><div><font face="arial, helvetica, sans-serif">       - {vgname: &#39;vg_sdb&#39;, thinpoolname: &#39;foo_thinpool&#39;, thinpoolsize: &#39;100G&#39;, poolmetadatasize: &#39;16G&#39;</font></div><div><font face="arial, helvetica, sans-serif">       - {vgname: &#39;vg_sdc&#39;, thinpoolname: &#39;bar_thinpool&#39;, thinpoolsize: &#39;500G&#39;, poolmetadatasize: &#39;16G&#39;</font></div><div><font face="arial, helvetica, sans-serif">       ^ here</font></div><div><font face="arial, helvetica, sans-serif">This one looks easy to fix.  It seems that there is a value started</font></div><div><font face="arial, helvetica, sans-serif">with a quote, and the YAML parser is expecting to see the line ended</font></div><div><font face="arial, helvetica, sans-serif">with the same kind of quote.  For instance:</font></div><div><font face="arial, helvetica, sans-serif"><br></font></div></div></div></div></div></div></blockquote><div><br></div><div>Yeah the closing brace `}&#39; is missing. This is fixed in upstream by PR: <a href="https://github.com/gluster/gluster-ansible-infra/pull/28" target="_blank">https://github.com/gluster/gluster-ansible-infra/pull/28</a><br></div></div></div></div></div></blockquote><div><br></div><div>The testing and CI work is being done role by role with molecule[1]. 
Molecule runs both yamllint and ansible-lint. It&#39;s been catching lint errors 
in the two roles we&#39;ve worked with so far.<br><div><br></div></div><div>[1]: <a href="https://molecule.readthedocs.io/">https://molecule.readthedocs.io/</a> <br></div></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr">nigelb<br></div></div></div></div></div>