avinetworks.avise_vmware

⛔️ DEPRECATED: This repository is no longer maintained. Please use https://github.com/vmware/ansible-collection-alb instead as this role has been moved to Ansible collections.

Ansible Galaxy

This module lets you install the Avi Vantage Service Engine on your system. However, you must meet certain requirements. For details, check the Avi SE Requirements page: Requirements

Requirements

  • You need the avisdk Python library. Install it with: pip install avisdk --upgrade
  • You also need pyvmomi, which you can install using: pip install pyvmomi --upgrade
  • Lastly, install requests_toolbelt with: pip install requests_toolbelt --upgrade

Role Dependencies

  • Install avinetworks.avisdk with this command: ansible-galaxy install -f avinetworks.avisdk

Role Variables

Standard Parameters

Variable Required Default Comments
se_skip_requirements No false Skip disk space, RAM, and CPU checks.

Auto-registration and Controller specific parameters

Variable Required Default Comments
se_autoregister No true Automatically register the service engine with the specified controller.
se_auth_token No None Token used for registration, if provided.
se_cluster_uuid No None UUID for the cluster during registration, if provided.
se_master_ctl_ip Yes None The IP address of the controller.
se_master_ctl_username No None Username to access the controller API.
se_master_ctl_password No None Password for the controller API.
se_tenant No admin Name of the tenant for auto-registration.
se_cloud_name No Default-Cloud Name of the cloud for auto-registration.
se_group_name No Default-Group Name of the group for the service engine.

VMware Deployment Variables

These are mandatory only for VMware deployment.

Variable Required Default Comments
vcenter_host Yes None VMware host IP.
vcenter_user Yes None VMware username.
vcenter_password Yes None VMware password.
ssl_verify No False SSL verification option for ovftool.
state No present Specify if you want to create or destroy the infrastructure.
se_vmw_datacenter No First from the list Name of the VMware datacenter.
se_vmw_cluster No First from the clusters in the datacenter Name of the cluster.
se_vmw_datastore No One with maximum free space Datastore for VM deployment.
se_vmw_ovf_networks No None Names of OVF networks as key-value pairs.
se_vmw_disk_mode No thin Disk mode for deployment.
se_vmw_ova_image_file No se.ova Name of the SE OVA file to find on the controller.
se_vmw_ova_image_name No None Name for the downloaded OVA file.
se_vmw_ova_path No None Location of the OVA file (includes filename).
se_vmw_ova_download_path No . Location to download the SE OVA (excludes filename).
se_vmw_vm_name Yes None Name for the controller VM in VMware.
se_vmw_power_on No True Whether to power on the VM after provisioning.
se_vmw_vcenter_folder No Datacenter root Folder path for VM deployment.
se_vmw_mgmt_ip No None Static IP for the controller.
se_vmw_mgmt_mask No None Management IP Mask.
se_vmw_default_gw No None Default gateway for the management network.
se_vmw_sysadmin_public_key No None Path for the public key file.
se_vmw_number_of_cpus No None Number of CPUs for the controller.
se_vmw_cpu_reserved No None CPU reservation in megahertz.
se_vmw_memory No None Memory in MB for the controller.
se_vmw_memory_reserved No None Memory reservation in MB for the controller.
se_vmw_disk_size No None Disk size in GB for the controller.
se_vmw_ovf_properties No None Other OVF properties in key-value format.

VMware Deployment Example

---
- hosts: controller
  roles:
    - name: avinetworks.avisdk
    - role: avinetworks.avise_vmware
      vars:
        se_master_ctl_ip: '{{ controller_ip }}'
        se_master_ctl_username: '{{ controller_username }}'
        se_master_ctl_password: '{{ controller_password }}'
        se_cloud_name: Default-Cloud
        ovftool_path: /usr/bin/
        vcenter_host: '{{ vcenter_host }}'
        vcenter_user: '{{ vcenter_user }}'
        vcenter_password: '{{ vcenter_password }}'
        se_vmw_datacenter: VMW_DC
        se_vmw_cluster: VMW_CL
        se_vmw_ovf_networks:
          'Data Network 1': DPG-80
          'Data Network 2': DPG-100
          'Management': Mgmt_network
        se_vmw_vm_name: ansible-avise-vmware
        se_vmw_power_on: true
        se_vmw_vcenter_folder: network/avi
        se_vmw_number_of_cpus: 2
        se_vmw_memory: 2048

VMware Cloud on AWS (VMC) Example with Auto-registration

For VMware Cloud on AWS (VMC), all network interfaces need to be tied to a port group. For unused interfaces, you can use the parking port group.

---
- hosts: localhost
  gather_facts: no
  connection: local
  roles:
    - name: avinetworks.avisdk
  vars:
    avi_credentials:
      api_version: "{{ avi_api_version }}"
      username: "{{ avi_username }}"
      password: "{{ avi_password }}"
      controller: "{{ controllers.0.mgmt_ip }}"
  tasks:
    - name: Deploy Avi Service Engines
      include_role:
        name: avinetworks.avise_vmware
      vars:
        se_master_ctl_ip: '{{ controllers.0.mgmt_ip }}'
        se_master_ctl_username: '{{ avi_username }}'
        se_master_ctl_password: '{{ avi_password }}'
        se_cloud_name: '{{ cloud_name }}'
        se_group_name: '{{ seg_name }}'
        ovftool_path: /usr/bin/
        vcenter_host: '{{ vcenter_host }}'
        vcenter_user: '{{ vcenter_user }}'
        vcenter_password: '{{ vcenter_password }}'
        se_vmw_datacenter: '{{ con_vcenter_datacenter }}'
        se_vmw_cluster: '{{ con_vcenter_cluster }}'
        se_vmw_vcenter_folder: '{{ seg_vcenter_folder }}'
        se_vmw_datastore: '{{ serviceengines.0.se_vcenter_datastore }}'
        se_vmw_vm_name: "{{ serviceengines.0.vm_name }}"
        se_vmw_power_on: '{{ serviceengines.0.power_on }}'
        se_vmw_ovf_networks:
          'Data Network 9': '{{ seg_parking_network }}'
          'Data Network 8': '{{ seg_parking_network }}'
          'Data Network 7': '{{ seg_parking_network }}'
          'Data Network 6': '{{ seg_parking_network }}'
          'Data Network 5': '{{ seg_parking_network }}'
          'Data Network 4': '{{ seg_parking_network }}'
          'Data Network 3': '{{ seg_parking_network }}'
          'Data Network 2': '{{ seg_parking_network }}'
          'Data Network 1': '{{ seg_data1_network }}'
          'Management': '{{ seg_mgmt_network }}'
        se_vmw_power_on: true
        se_vmw_number_of_cpus: '{{ seg_cpus }}'
        se_vmw_memory: '{{ seg_memory }}'
        se_vmw_memory_reserved: '{{ seg_memory }}'
        se_vmw_disk_size: '{{ seg_disk }}'
        se_vmw_disk_mode: thick
      loop: "{{ serviceengines }}"

VMware Example without Auto-registration

---
- hosts: controller
  roles:
    - name: avinetworks.avisdk
    - role: avinetworks.avise_vmware
      vars:
        se_master_ctl_ip: '{{ controller_ip }}'
        se_master_ctl_username: '{{ controller_username }}'
        se_master_ctl_password: '{{ controller_password }}'
        se_cloud_name: Default-Cloud
        ovftool_path: /usr/bin/
        vcenter_host: '{{ vcenter_host }}'
        vcenter_user: '{{ vcenter_user }}'
        vcenter_password: '{{ vcenter_password }}'

        se_autoregister: false
        se_auth_token: '{{ se_authtoken }}'
        se_cluster_uuid: '{{ se_clusteruuid }}'

        se_vmw_datacenter: VMW_DC
        se_vmw_cluster: VMW_CL
        se_vmw_ovf_networks:
          'Data Network 1': DPG-80
          'Data Network 2': DPG-100
          'Management': Mgmt_network
        se_vmw_vm_name: ansible-avise-vmware
        se_vmw_power_on: true
        se_vmw_vcenter_folder: network/avi
        se_vmw_number_of_cpus: 2
        se_vmw_memory: 2048

License

Apache 2.0

Author Information

For inquiries, contact: Avi Networks at [avi-sdk@avinetworks.com]

Installa
ansible-galaxy install avinetworks.avise_vmware
Licenza
apache-2.0
Download
1.2k
Proprietario