xlab_si.nuage_create_entity

Ansible Role: nuage_create_entity

This role helps you create any entity on the Nuage server and can also link it to a parent entity if you choose.

Requirements

You need to install a package using:

pip install vspk

Role Variables

Variable Default Description
nuage_auth / The Nuage authentication object; see the example below.
entity_type / The name of the entity you are creating, in CamelCase (e.g. Enterprise, Domain, Subnet, FloatingIp).
attributes / The desired attributes for the new entity.
parent_type null The type of the parent entity (optional).
parent_id null The ID of the parent entity (optional).

Outputs

When this role runs, it provides the following custom stats:

Stats name Description
created_entity A record of the created entity.

Dependencies

This role does not depend on any other Galaxy role.

Example Playbook

Here’s how to create an Enterprise with the name DEMO:

- hosts: localhost
  connection: local
  gather_facts: False
  vars:
    nuage_auth:
      api_username: user
      api_password: pass
      api_enterprise: csp
      api_url: https://my.nuage.net
      api_version: v5_0
    entity_type: Enterprise
    attributes:
      name: DEMO
  roles:
    - xlab_si.nuage_create_entity

Here’s how to create a Subnet with the name DEMO and link it to a parent Domain with ID ebd14a5e-a2cd-4302-bb04-89e2f4a827fe:

- hosts: localhost
  connection: local
  gather_facts: False
  vars:
    nuage_auth:
      api_username: user
      api_password: pass
      api_enterprise: csp
      api_url: https://my.nuage.net
      api_version: v5_0
    entity_type: Subnet
    attributes:
      name: DEMO
    parent_type: Domain
    parent_id: ebd14a5e-a2cd-4302-bb04-89e2f4a827fe
  roles:
    - xlab_si.nuage_create_entity

License

BSD

Informazioni sul progetto

Ansible role to create any Nuage entity and optionally connect it to parent entity.

Installa
ansible-galaxy install xlab_si.nuage_create_entity
Licenza
Unknown
Download
38.6k
Proprietario
Research and development company based in Ljubljana, Slovenia.