OASIS Topology and Orchestration Specification for Cloud Applications (TOSCA) TC

 View Only

Re: [tosca] TOSCA for Ansible

  • 1.  Re: [tosca] TOSCA for Ansible

    Posted 03-15-2021 08:13



    Ciao Tal


    indeed the double colon notation seems interesting, thanks for the example! btw, I ll try to send your way a few examples on how we managed to achieve something similar with Ansible in RADON and SODALITE


    D.




























    Damian A. Tamburri, Ph.D.
    Associate Professor 


    TU/e - JADS - 
    https://www.jads.nl/
    Sint Janssingel 92, s Hertogenbosch 

    Room 2.18, 2nd Floor



    Email: d.a.tamburri@tue.nl
    Cell: +39 3491279924
    Web: https://www.researchgate.net/profile/Damian_Tamburri

    Executive Director, Jheronimus Academy Data & Engineering (JADE) Lab
    Secretary, OASIS Topology and Orchestration for Cloud Applications  (TOSCA) Standard Technical Committee
    Secretary, IFIP - WG 2.14 / 6.12 / 8.10 on Service-Oriented Systems
    Associate Editor & Online Presence Director, ACM Transactions on Software Engineering & Methodology (TOSEM)



















































    On 12 Mar 2021, at 19:30, Tal Liron < tliron@redhat.com > wrote:



    So, I did find a way to generate Ansible's inventory dynamically from TOSCA.


    What's interesting about my solution is that it requires nothing specific on the TOSCA side, no special types and no metadata. Instead, you have a "tosca.yaml" file used by the plugin to filter the node and/or capability types that you want to
    consider as "hosts". This means it can work with any TOSCA profile for any environment. What's left to do is mapping properties or attributes to required Ansible host configurations.


    What's also interesting about this use case is that it does require a universal way to refer to types. That's where Puccini's "canonical type names" come into play, where I use the double-colon to specify the unambiguous names, e.g. "tosca::Container"
    ("tosca" here being not a user-specifed import namespace but the universal profile name). We've argued before over whether TOSCA should specify a canonical type name format, and I would say this is a good example of where it would be beneficial to have a standard.


    https://github.com/tliron/puccini/tree/main/examples/ansible/hosts