Deploy a Skyline collector using Ansible playbook

Share on:

Example Ansible playbook to deploy a Skyline collector:

Download the Skyline collector ova from vmware.com

Download Playbook: here

You have to adjust the parameters based on your environment. Folder path can easily be found using govc.

 1root@jumper:~/ansible-VMware# govc vm.info testmachine
 2Name:           testmachine
 3  Path:         /Homelab/vm/testmachine
 4  UUID:         4220445a-9c53-74cd-a1d6-978c21fcb087
 5  Guest name:   Other 3.x or later Linux (64-bit)
 6  Memory:       8192MB
 7  CPU:          4 vCPU(s)
 8  Power state:  poweredOn
 9  Boot time:    2022-01-09 12:30:07.998044 +0000 UTC
10  IP address:   192.168.19.25
11  Host:         esxi.local

Based on this output the folder path is "Homelab/vm"

 1---
 2- hosts: local
 3  connection: local
 4  become: no
 5  gather_facts: False
 6  vars:
 7    ansible_python_interpreter: /usr/bin/python3
 8  tasks:
 9  - name: Deploy VMware Skyline Collector OVA
10    vmware_deploy_ovf:
11      hostname: vcsa.local
12      username: administrator@vsphere.local
13      password: VMware123!
14      validate_certs: no
15      name: VMware-Skyline-Collector
16      datacenter: Homelab
17      cluster: Cluster
18      folder: /Homelab/vm
19      datastore: datastore01
20      disk_provisioning: thin
21      networks:
22        "Network 1": "VM Network"
23      ova: /home/user/ansible-VMware/Skyline-Appliance-3.0.0.0-18775414_OVF10.ova
24      allow_duplicates: no
25      power_on: yes
26      fail_on_spec_warnings: yes
27      wait: yes
28      wait_for_ip_address: yes
29      inject_ovf_env: yes
30      properties:
31        varoot-password: "VMware123!"
32        vami.ip0.VMware_Skyline_Appliance: 192.168.19.49
33        vami.netmask0.VMware_Skyline_Appliance: 255.255.255.0
34        vami.gateway.VMware_Skyline_Appliance: 192.168.19.1
35        vami.DNS.VMware_Skyline_Appliance: 192.168.19.1
36        vami.searchpath.VMware_Skyline_Appliance: local
37        vami.domain.VMware_Skyline_Appliance: skyline.local
38    delegate_to: localhost

Run the playbook:

 1root@jumper:~/ansible-VMware# ansible-playbook skyline_vmware_deploy_ova.yml
 2
 3PLAY [local] ***********************************************************************************************************************************************************************************************
 4
 5TASK [Deploy VMware Skyline Collector OVA] *****************************************************************************************************************************************************************
 6changed: [localhost -> localhost]
 7
 8PLAY RECAP *************************************************************************************************************************************************************************************************
 9localhost                  : ok=1    changed=1    unreachable=0    failed=0    skipped=0    rescued=0    ignored=0
10
11root@jumper:~/ansible-VMware#