【发布时间】:2021-08-26 06:51:26
【问题描述】:
我想使用 Ansible 将新 VM 添加到现有的 VMware VM/主机组(DRS 组)。但是,对于下面列出的模块,始终会学习完整的组,并且只添加这一个 VM。 如何将新 VM 添加到 DRS 角色而不删除其中已有的 VM?
- name: "Create DRS VM group"
delegate_to: localhost
vmware_drs_group:
hostname: "{{ vcenter_hostname }}"
password: "{{ vcenter_password }}"
username: "{{ vcenter_username }}"
cluster_name: DC0_C0
datacenter_name: DC0
group_name: TEST_VM_01
vms:
- DC0_C0_RP0_VM0
- DC0_C0_RP0_VM1
state: present
【问题讨论】: