This commit is contained in:
parent
ad0c511651
commit
ff555ce0de
@ -25,7 +25,6 @@
|
||||
community.vmware.vmware_deploy_ovf:
|
||||
cluster: "{{ vcenter_info.cluster }}"
|
||||
datastore: "{{ vcenter_info.datastore }}"
|
||||
folder: "{{ vcenter_info.folder }}"
|
||||
name: "{{ (item | basename | split('.'))[:-1] | join('.') }}"
|
||||
networks: "{u'{{ ova_spec.results[index].stdout | from_json | json_query('NetworkMapping[0].Name') }}':u'{{ vcenter_info.network }}'}"
|
||||
allow_duplicates: no
|
||||
@ -37,26 +36,25 @@
|
||||
loop_control:
|
||||
index_var: index
|
||||
|
||||
- name: Add vApp properties on deployed VM's
|
||||
ansible.builtin.shell:
|
||||
cmd: >-
|
||||
npp-prepper \
|
||||
--server "{{ vapp['hv.fqdn'] }}" \
|
||||
--username "{{ vapp['hv.username'] }}" \
|
||||
--password "{{ vapp['hv.password'] }}" \
|
||||
vm \
|
||||
--datacenter "{{ vcenter_info.datacenter }}" \
|
||||
--portgroup "{{ vcenter_info.network }}" \
|
||||
--name "{{ item.instance.hw_name }}"
|
||||
when: existing_ova.results[index] is failed
|
||||
loop: "{{ ova_deploy.results }}"
|
||||
loop_control:
|
||||
index_var: index
|
||||
label: "{{ item.item }}"
|
||||
# - name: Add vApp properties on deployed VM's
|
||||
# ansible.builtin.shell:
|
||||
# cmd: >-
|
||||
# npp-prepper \
|
||||
# --server "{{ vapp['hv.fqdn'] }}" \
|
||||
# --username "{{ vapp['hv.username'] }}" \
|
||||
# --password "{{ vapp['hv.password'] }}" \
|
||||
# vm \
|
||||
# --datacenter "{{ vcenter_info.datacenter }}" \
|
||||
# --portgroup "{{ vcenter_info.network }}" \
|
||||
# --name "{{ item.instance.hw_name }}"
|
||||
# when: existing_ova.results[index] is failed
|
||||
# loop: "{{ ova_deploy.results }}"
|
||||
# loop_control:
|
||||
# index_var: index
|
||||
# label: "{{ item.item }}"
|
||||
|
||||
- name: Create snapshot on deployed VM's
|
||||
community.vmware.vmware_guest_snapshot:
|
||||
folder: "{{ vcenter_info.folder }}"
|
||||
name: "{{ item.instance.hw_name }}"
|
||||
state: present
|
||||
snapshot_name: "{{ ansible_date_time.iso8601_basic_short }}-base"
|
||||
@ -83,3 +81,4 @@
|
||||
username: "{{ vapp['hv.username'] }}"
|
||||
password: "{{ vapp['hv.password'] }}"
|
||||
datacenter: "{{ vcenter_info.datacenter }}"
|
||||
folder: "{{ vcenter_info.folder }}"
|
||||
|
@ -59,6 +59,8 @@ patchesStrategicMerge:
|
||||
- apiGroup: ipam.cluster.x-k8s.io
|
||||
kind: InClusterIPPool
|
||||
name: inclusterippool-${CLUSTER_NAME}
|
||||
nameservers:
|
||||
- {{ _template.network.dnsserver }}
|
||||
networkName: '${VSPHERE_NETWORK}'
|
||||
- |-
|
||||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1
|
||||
|
Loading…
Reference in New Issue
Block a user