<div dir="ltr">Aaron,<div><br></div><div>Thanks for sharing the feedback, I opened an issue so we can track this:</div><div> <a href="https://github.com/fusor/ansible-playbook-bundle/issues/94">https://github.com/fusor/ansible-playbook-bundle/issues/94</a></div><div><br></div><div><br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Aug 7, 2017 at 2:01 PM, Aaron Weitekamp <span dir="ltr"><<a href="mailto:aweiteka@redhat.com" target="_blank">aweiteka@redhat.com</a>></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><div>When I started creating apb applications I wanted to develop my application locally just using ansible. Building, pushing, running my application was something to be done at the end. More than likely, building and testing the actual APB image is a post-commit operation performed in a gating source control test job.<br><br></div>The problem with this is that while ansible has many patterns[1] for passing in variables (aka parameters), we've invented a new pattern in apb.yml. The risk is that application developers put defaults into their playbooks[2], not realizing they're also defined (and overridden via --extra-vars) in apb.yml[3]. In this example we've gone out of our way to be DRY in the apb.yml yet none of these are used when running ansible-playbook locally. Some vars may not be exposed to the end-user but these should be limited.<br><br></div><div>Some options I've explored:<br></div><div><div>- support an "include vars files" pattern in apb.yml. However, I don't see a way to associate metadata (display, description, type).<br></div><div><div>- create a module to gather apb facts. See aws example[4]<br></div><div>- extend apb CLI to inject vars during test<br></div><div>- use a Makefile to inject vars during test<br></div></div>- do nothing. Local ansible application development needs to manually pass in --extra-vars for every item in apb.yml.<br></div><br>[1] include file, inventory host/group vars, inline playbook, role defaults, CLI<br>[2] example: <a href="https://github.com/fusor/apb-examples/blob/master/jenkins-apb/roles/provision-jenkins-apb/defaults/main.yml" target="_blank">https://github.com/fusor/apb-<wbr>examples/blob/master/jenkins-<wbr>apb/roles/provision-jenkins-<wbr>apb/defaults/main.yml</a><br>[3] example: <a href="https://github.com/fusor/apb-examples/blob/master/jenkins-apb/apb.yml" target="_blank">https://github.com/fusor/apb-<wbr>examples/blob/master/jenkins-<wbr>apb/apb.yml</a> <br>[4] <a href="http://docs.ansible.com/ansible/latest/ec2_facts_module.html" target="_blank">http://docs.ansible.com/<wbr>ansible/latest/ec2_facts_<wbr>module.html</a><br><br></div>
<br>______________________________<wbr>_________________<br>
Ansible-service-broker mailing list<br>
<a href="mailto:Ansible-service-broker@redhat.com">Ansible-service-broker@redhat.<wbr>com</a><br>
<a href="https://www.redhat.com/mailman/listinfo/ansible-service-broker" rel="noreferrer" target="_blank">https://www.redhat.com/<wbr>mailman/listinfo/ansible-<wbr>service-broker</a><br>
<br></blockquote></div><br></div></div></div>